public final class JacksonUtils extends Object
This class provides a custom JsonNodeFactory
and ObjectReader
which you should use preferably to your own (in particular,
the reader ensures that decimal values are read using BigDecimal
.
It also provides a method for returning an empty ObjectNode
(for all practical purposes, an empty schema), and one to convert a JSON
object into a Map
.
Modifier and Type | Method and Description |
---|---|
static Map<String,JsonNode> |
asMap(JsonNode node)
Return a map out of an object's members
|
static ObjectReader |
getReader()
Return a preconfigured
ObjectReader to read JSON inputs |
static JsonNodeFactory |
nodeFactory()
Return a preconfigured
JsonNodeFactory to generate JSON data as
JsonNode s |
public static ObjectReader getReader()
ObjectReader
to read JSON inputspublic static JsonNodeFactory nodeFactory()
JsonNodeFactory
to generate JSON data as
JsonNode
sCopyright © 2013. All Rights Reserved.