public class Utils extends Object
Modifier and Type | Field and Description |
---|---|
static Pattern |
ARRAY_ELEMENT_INDEX |
Constructor and Description |
---|
Utils() |
Modifier and Type | Method and Description |
---|---|
static void |
consumeFully(org.apache.http.HttpEntity entity)
If the passed entity has content, make sure it is fully
read and closed.
|
static Object |
fromJSON(byte[] utf8) |
static Object |
fromJSON(InputStream is) |
static Object |
fromJSONResource(String resourceName) |
static Object |
fromJSONString(String json) |
static Collection |
getDeepCopy(Collection c,
int maxDepth,
boolean mutable) |
static Map |
getDeepCopy(Map map,
int maxDepth) |
static Map |
getDeepCopy(Map map,
int maxDepth,
boolean mutable) |
static Object |
getObjectByPath(Map root,
boolean onlyPrimitive,
List<String> hierarchy) |
static Object |
getObjectByPath(Map root,
boolean onlyPrimitive,
String hierarchy) |
static Map<String,Object> |
makeMap(Object... keyVals) |
static byte[] |
toJSON(Object o) |
static String |
toJSONString(Object o) |
static byte[] |
toUTF8(org.noggit.CharArr out) |
public static final Pattern ARRAY_ELEMENT_INDEX
public static Collection getDeepCopy(Collection c, int maxDepth, boolean mutable)
public static byte[] toJSON(Object o)
public static byte[] toUTF8(org.noggit.CharArr out)
public static Object fromJSON(byte[] utf8)
public static Object fromJSON(InputStream is)
public static Object getObjectByPath(Map root, boolean onlyPrimitive, String hierarchy)
public static Object getObjectByPath(Map root, boolean onlyPrimitive, List<String> hierarchy)
public static void consumeFully(org.apache.http.HttpEntity entity)
entity
- to consume or nullCopyright © 2000-2017 Apache Software Foundation. All Rights Reserved.