mirror of
https://github.com/processing/processing4.git
synced 2026-02-13 02:20:45 +01:00
Initial mobile website check in
This commit is contained in:
55
mobile/web/reference/API/String_substring.xml
Normal file
55
mobile/web/reference/API/String_substring.xml
Normal file
@@ -0,0 +1,55 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
||||
<root>
|
||||
|
||||
<name>substring()</name>
|
||||
|
||||
<category>String</category>
|
||||
|
||||
<subcategory>Method</subcategory>
|
||||
|
||||
<usage>Web & Application</usage>
|
||||
|
||||
<example>
|
||||
<image></image>
|
||||
<code>
|
||||
String str1 = "CCCP";
|
||||
String str2 = "Rabbit";
|
||||
String ss1 = str1.substring(2); // Returns "CP"
|
||||
String ss2 = str2.substring(3); // Returns "bit"
|
||||
String ss3 = str1.substring(0, 2); // Returns "CC"
|
||||
println(ss1 + ":" + ss2 + ":" + ss3); // Prints 'CP:bit:CC'
|
||||
</code>
|
||||
</example>
|
||||
|
||||
<description>
|
||||
Returns a new string that is a part of the original string. When using the <b>endIndex</b> parameter, the string between <b>beginIndex</b> and <b>endIndex</b>-1 is returned.
|
||||
</description>
|
||||
|
||||
<syntax>
|
||||
substring(<b>beginIndex</b>)
|
||||
substring(<b>beginIndex</b>, <b>endIndex</b>)
|
||||
</syntax>
|
||||
|
||||
<parameter>
|
||||
<label>beginIndex</label>
|
||||
<description>int: position from which to begin (inclusive)</description>
|
||||
</parameter>
|
||||
|
||||
<parameter>
|
||||
<label>endIndex</label>
|
||||
<description>int: position from which to end (exclusive)</description>
|
||||
</parameter>
|
||||
|
||||
<returns>None</returns>
|
||||
|
||||
<related>
|
||||
</related>
|
||||
|
||||
<availability>1.0</availability>
|
||||
|
||||
<type>Method</type>
|
||||
|
||||
<partof>Core</partof>
|
||||
|
||||
|
||||
</root>
|
||||
Reference in New Issue
Block a user