org.usergrid.utils
Class JsonUtils
java.lang.Object
org.usergrid.utils.JsonUtils
public class JsonUtils
- extends Object
- Author:
- edanuff
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
JsonUtils
public JsonUtils()
mapToJsonString
public static String mapToJsonString(Object obj)
- Parameters:
obj
-
- Returns:
mapToFormattedJsonString
public static String mapToFormattedJsonString(Object obj)
schemaToFormattedJsonString
public static String schemaToFormattedJsonString(org.codehaus.jackson.schema.JsonSchema schema)
getJsonSchema
public static org.codehaus.jackson.schema.JsonSchema getJsonSchema(Class<?> cls)
parse
public static Object parse(String json)
getJsonSchemaNode
public static org.codehaus.jackson.JsonNode getJsonSchemaNode(Class<?> cls)
quoteString
public static String quoteString(String s)
toByteBuffer
public static ByteBuffer toByteBuffer(Object obj)
fromByteBuffer
public static Object fromByteBuffer(ByteBuffer byteBuffer)
fromByteBuffer
public static Object fromByteBuffer(ByteBuffer byteBuffer,
Class<?> clazz)
nodeFromByteBuffer
public static org.codehaus.jackson.JsonNode nodeFromByteBuffer(ByteBuffer byteBuffer)
toJsonNode
public static org.codehaus.jackson.JsonNode toJsonNode(Object obj)
toJsonMap
public static Map<String,Object> toJsonMap(Object obj)
normalizeJsonTree
public static Object normalizeJsonTree(Object obj)
select
public static Object select(Object obj,
String path)
select
public static Object select(Object obj,
String path,
boolean buildResultTree)
loadFromResourceFile
public static Object loadFromResourceFile(String file)
loadFromFilesystem
public static Object loadFromFilesystem(String filename)
loadFromUrl
public static Object loadFromUrl(String urlStr)
loadFromUrl
public static Object loadFromUrl(URL url)
isSmile
public static boolean isSmile(ByteBuffer buffer)
Copyright © 2013. All Rights Reserved.