Home
last modified time | relevance | path

Searched refs:JSONArray (Results 1 – 11 of 11) sorted by relevance

/libcore/json/src/test/java/libcore/org/json/
DJSONArrayTest.java25 import org.json.JSONArray;
36 JSONArray array = new JSONArray(); in testEmptyArray()
60 assertNull(array.toJSONObject(new JSONArray())); in testEmptyArray()
64 JSONArray a = new JSONArray(); in testEqualsAndHashCode()
65 JSONArray b = new JSONArray(); in testEqualsAndHashCode()
82 JSONArray array = new JSONArray(); in testBooleans()
108 JSONArray other = new JSONArray(); in testBooleans()
117 other = new JSONArray(); in testBooleans()
132 JSONArray array = new JSONArray(); in testCoerceStringToBoolean()
144 JSONArray array = new JSONArray(); in testNulls()
[all …]
DJSONObjectTest.java35 import org.json.JSONArray;
53 assertNull(object.toJSONArray(new JSONArray())); in testEmptyObject()
461 JSONArray a = new JSONArray(); in testJSONObjects()
539 JSONArray names = new JSONArray(); in testToJSONArray()
544 JSONArray array = object.toJSONArray(names); in testToJSONArray()
559 JSONArray names = new JSONArray(); in testToJSONArrayMissingNames()
565 JSONArray array = object.toJSONArray(names); in testToJSONArrayMissingNames()
591 JSONArray array = new JSONArray(); in testToJSONArrayEndsUpEmpty()
602 JSONArray names = new JSONArray(); in testToJSONArrayNonString()
608 JSONArray array = object.toJSONArray(names); in testToJSONArrayNonString()
[all …]
DSelfUseTest.java21 import org.json.JSONArray;
82 private final JSONArray array = new JSONArray() {
83 @Override public JSONArray put(int index, Object value) throws JSONException {
214 JSONArray values = new JSONArray(); in testToJSONObject()
DParsingTest.java27 import org.json.JSONArray;
225 private JSONArray array(Object... elements) { in array()
226 return new JSONArray(Arrays.asList(elements)); in array()
254 if (input instanceof JSONArray) { in canonicalize()
255 JSONArray array = (JSONArray) input; in canonicalize()
DJSONStringerTest.java21 import org.json.JSONArray;
236 JSONArray array = new JSONArray(); in testJSONArrayAsValue()
317 JSONArray array = new JSONArray(); in testMaxDepthWithArrayValue()
DJSONTokenerTest.java22 import org.json.JSONArray;
582 JSONArray array = (JSONArray) tokener.nextValue(); in testBomIgnoredAsFirstCharacterOfDocument()
588 JSONArray array = (JSONArray) tokener.nextValue(); in testBomTreatedAsCharacterInRestOfDocument()
/libcore/json/src/main/java/org/json/
DJSONArray.java50 public class JSONArray { class
58 public JSONArray() { in JSONArray() method in JSONArray
71 public JSONArray(Collection copyFrom) { in JSONArray() method in JSONArray
89 public JSONArray(JSONTokener readFrom) throws JSONException { in JSONArray() method in JSONArray
95 if (object instanceof JSONArray) { in JSONArray()
96 values = ((JSONArray) object).values; in JSONArray()
109 public JSONArray(String json) throws JSONException { in JSONArray() method in JSONArray
116 public JSONArray(Object array) throws JSONException { in JSONArray() method in JSONArray
139 public JSONArray put(boolean value) { in put()
151 public JSONArray put(double value) throws JSONException { in put()
[all …]
DJSONObject.java314 if (current instanceof JSONArray) { in accumulate()
315 JSONArray array = (JSONArray) current; in accumulate()
318 JSONArray array = new JSONArray(); in accumulate()
341 final JSONArray array; in append()
342 if (current instanceof JSONArray) { in append()
343 array = (JSONArray) current; in append()
345 JSONArray newArray = new JSONArray(); in append()
594 @NonNull public JSONArray getJSONArray(@NonNull String name) throws JSONException { in getJSONArray()
596 if (object instanceof JSONArray) { in getJSONArray()
597 return (JSONArray) object; in getJSONArray()
[all …]
DJSONTokener.java415 private JSONArray readArray() throws JSONException { in readArray()
416 JSONArray result = new JSONArray(); in readArray()
DJSONStringer.java241 if (value instanceof JSONArray) { in value()
242 ((JSONArray) value).writeTo(this); in value()
/libcore/
Dnon_openjdk_java_files.bp68 "json/src/main/java/org/json/JSONArray.java",