|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.mongodb.util.JSON
public class JSON
Helper methods for JSON serialization and de-serialization
| Constructor Summary | |
|---|---|
JSON()
|
|
| Method Summary | |
|---|---|
static Object |
parse(String s)
Parses a JSON string representing a JSON value |
static Object |
parse(String s,
BSONCallback c)
Parses a JSON string representing a JSON value |
static String |
serialize(Object o)
Serializes an object into its JSON form. |
static void |
serialize(Object o,
StringBuilder buf)
Serializes an object into its JSON form. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public JSON()
| Method Detail |
|---|
public static String serialize(Object o)
This method delegates serialization to JSONSerializers.getLegacy
o - object to serialize
JSONSerializers.getLegacy()
public static void serialize(Object o,
StringBuilder buf)
This method delegates serialization to JSONSerializers.getLegacy
o - object to serializebuf - StringBuilder containing the JSON representation under constructionJSONSerializers.getLegacy()public static Object parse(String s)
s - the string to parse
public static Object parse(String s,
BSONCallback c)
s - the string to parse
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||