public class JSONArray<T> extends ArrayList<T> implements List<T>, JSONAware
modCount| Constructor and Description |
|---|
JSONArray() |
JSONArray(Collection<? extends T> c) |
| Modifier and Type | Method and Description |
|---|---|
String |
toJSONString()
Encodes this object to a JSON string.
|
static String |
toJSONString(boolean[] ary)
Convert a boolean array to JSON text.
|
static String |
toJSONString(byte[] ary)
Convert a byte array to JSON text.
|
static String |
toJSONString(char[] ary)
Convert a char array to JSON text.
|
static String |
toJSONString(Collection collection)
Convert a list to JSON text.
|
static String |
toJSONString(double[] ary)
Convert a double array to JSON text.
|
static String |
toJSONString(float[] ary)
Convert a float array to JSON text.
|
static String |
toJSONString(int[] ary)
Convert an integer array to JSON text.
|
static String |
toJSONString(long[] ary)
Convert a long array to JSON text.
|
static String |
toJSONString(Object[] ary)
Convert an object array to JSON text.
|
static String |
toJSONString(short[] ary)
Convert a short array to JSON text.
|
String |
toString()
Encodes this object to a JSON string.
|
add, add, addAll, addAll, clear, clone, contains, ensureCapacity, forEach, get, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, removeIf, removeRange, replaceAll, retainAll, set, size, sort, spliterator, subList, toArray, toArray, trimToSizeequals, hashCodecontainsAllfinalize, getClass, notify, notifyAll, wait, wait, waitadd, add, addAll, addAll, clear, contains, containsAll, equals, get, hashCode, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, replaceAll, retainAll, set, size, sort, spliterator, subList, toArray, toArrayparallelStream, removeIf, streampublic JSONArray()
public JSONArray(Collection<? extends T> c)
public static String toJSONString(Collection collection)
collection - JSONValue.toJSONString(Object)public static String toJSONString(Object[] ary)
patched by tomyeh
public static String toJSONString(int[] ary)
patched by tomyeh
public static String toJSONString(long[] ary)
patched by tomyeh
public static String toJSONString(short[] ary)
patched by tomyeh
public static String toJSONString(float[] ary)
patched by tomyeh
public static String toJSONString(double[] ary)
patched by tomyeh
public static String toJSONString(byte[] ary)
patched by tomyeh
public static String toJSONString(boolean[] ary)
patched by tomyeh
public static String toJSONString(char[] ary)
patched by tomyeh
public String toJSONString()
toString().toJSONString in interface JSONAwarepublic String toString()
toJSONString().toString in class AbstractCollection<T>Copyright © 2020. All rights reserved.