public class JSONValue extends Object
Constructor and Description |
---|
JSONValue() |
Modifier and Type | Method and Description |
---|---|
static String |
escape(String s)
Escape quotes, \, /, \r, \n, \b, \f, \t and other control characters
(U+0000 through U+001F).
|
static Object |
parseWithException(Reader in)
Parse JSON text into java object from the input source.
|
static Object |
parseWithException(String s) |
static String |
toJSONString(Object value)
Convert an object to JSON text.
|
static void |
writeJSONString(Object value,
Writer out)
Encode an object into JSON text and write it to out.
|
public static void writeJSONString(Object value, Writer out) throws IOException
public static String toJSONString(Object value)
JSONObject.toJSONString(Map)
,
JSONArray.toJSONString(List)
public static String escape(String s)
public static Object parseWithException(Reader in) throws IOException, ParseException
IOException
ParseException
public static Object parseWithException(String s) throws ParseException
ParseException
Copyright © 2016. All Rights Reserved.