MCPcopy Index your code
hub / github.com/benfry/processing4 / join

Method join

core/src/processing/data/JSONArray.java:1338–1349  ·  view source on GitHub ↗

Make a string from the contents of this JSONArray. The separator string is inserted between each element. Warning: This method assumes that the data structure is acyclic. @param separator A string that will be inserted between the elements. @return a string. @throws RuntimeException If

(String separator)

Source from the content-addressed store, hash-verified

1336 * @throws RuntimeException If the array contains an invalid number.
1337 */
1338 public String join(String separator) {
1339 int len = this.size();
1340 StringBuilder sb = new StringBuilder();
1341
1342 for (int i = 0; i < len; i += 1) {
1343 if (i > 0) {
1344 sb.append(separator);
1345 }
1346 sb.append(JSONObject.valueToString(this.myArrayList.get(i)));
1347 }
1348 return sb.toString();
1349 }
1350}

Callers

nothing calls this directly

Calls 5

sizeMethod · 0.95
valueToStringMethod · 0.95
getMethod · 0.65
appendMethod · 0.45
toStringMethod · 0.45

Tested by

no test coverage detected