public class JSONUtils extends Object
| Constructor and Description |
|---|
JSONUtils() |
| Modifier and Type | Method and Description |
|---|---|
static Object |
deserializeCollection(String s,
org.codehaus.jackson.type.JavaType type) |
static Object |
deserializeObject(String s,
Class<?> clazz) |
static Object |
deserializeObject(String s,
org.codehaus.jackson.type.TypeReference<?> typeReference) |
static org.codehaus.jackson.type.JavaType |
getCollectionType(Class<?> collectionClass,
Class<?>... elementClasses) |
static String |
serializeObject(Object o) |
public static String serializeObject(Object o) throws IOException
IOExceptionpublic static Object deserializeObject(String s, Class<?> clazz) throws IOException
IOExceptionpublic static Object deserializeObject(String s, org.codehaus.jackson.type.TypeReference<?> typeReference) throws IOException
IOExceptionpublic static org.codehaus.jackson.type.JavaType getCollectionType(Class<?> collectionClass, Class<?>... elementClasses)
public static Object deserializeCollection(String s, org.codehaus.jackson.type.JavaType type) throws IOException
IOExceptionCopyright © 2018 Alibaba Group. All rights reserved.