Class JSONUtils
- java.lang.Object
-
- com.couchbase.lite.internal.utils.JSONUtils
-
public final class JSONUtils extends Object
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static List<Object>
fromJSON(org.json.JSONArray json)
static Map<String,Object>
fromJSON(org.json.JSONObject json)
static Date
toDate(String json)
static Object
toJSON(Object val)
static org.json.JSONArray
toJSON(List<?> list)
static org.json.JSONObject
toJSON(Map<?,?> map)
static String
toJSONString(Date date)
-
-
-
Method Detail
-
toJSON
@NonNull public static org.json.JSONObject toJSON(@NonNull Map<?,?> map) throws org.json.JSONException
- Throws:
org.json.JSONException
-
toJSON
@NonNull public static org.json.JSONArray toJSON(@NonNull List<?> list) throws org.json.JSONException
- Throws:
org.json.JSONException
-
toJSON
@Nullable public static Object toJSON(@Nullable Object val) throws org.json.JSONException
- Throws:
org.json.JSONException
-
fromJSON
@NonNull public static Map<String,Object> fromJSON(@NonNull org.json.JSONObject json) throws org.json.JSONException
- Throws:
org.json.JSONException
-
fromJSON
@NonNull public static List<Object> fromJSON(@NonNull org.json.JSONArray json) throws org.json.JSONException
- Throws:
org.json.JSONException
-
-