MCPcopy Create free account
hub / github.com/codenameone/CodenameOne / split

Method split

CodenameOne/src/com/codename1/io/Util.java:1755–1772  ·  view source on GitHub ↗
(String original, String separator)

Source from the content-addressed store, hash-verified

1753 ///
1754 /// array of Strings from the original String
1755 public static String[] split(String original, String separator) {
1756
1757 Vector nodes = new Vector();
1758
1759 int index = original.indexOf(separator);
1760 while (index >= 0) {
1761 nodes.addElement(original.substring(0, index));
1762 original = original.substring(index + separator.length());
1763 index = original.indexOf(separator);
1764 }
1765 nodes.addElement(original);
1766
1767 String[] ret = new String[nodes.size()];
1768 for (int i = 0; i < nodes.size(); i++) {
1769 ret[i] = (String) nodes.elementAt(i);
1770 }
1771 return ret;
1772 }
1773
1774 static CodenameOneImplementation getImplementation() {
1775 return implInstance;

Callers 15

addScopesMethod · 0.95
extractMonthNameMethod · 0.95
runMethod · 0.95
getParamsFromURLMethod · 0.95
mergeMethod · 0.95
decorateMethod · 0.95
parseMethod · 0.95
removeTagsMethod · 0.95
setReferencePositionsMethod · 0.95
setInsetsMethod · 0.95
parseStringMethod · 0.95

Calls 6

addElementMethod · 0.95
sizeMethod · 0.95
elementAtMethod · 0.95
indexOfMethod · 0.65
substringMethod · 0.65
lengthMethod · 0.65

Tested by 1