The latest Jackson version is 2.9.7, I was also told that 2.9.8 will have
some JDK 9+ compatibility work done on it.
I would say; try 2.9.7 and see if you don't get that error, here is the
link to the JDK 9+ comment:
https://github.com/FasterXML/jackson-dataformats-binary/issues/153#issuecomment
See the following Java Docs:
- *JsonNode:*
https://fasterxml.github.io/jackson-databind/javadoc/2.9/com/fasterxml/jackson/databind/JsonNode.html
- *TreeNode which is the superclass of JsonNode:*
http://fasterxml.github.io/jackson-core/javadoc/2.9/com/fasterxml/jackson/core/TreeNode.html
On Tue
You can also deserialize as JsonNode:
JsonNode json = new ObjectMapper.readValue(jsonString, JsonNode.class);
That will take care of the Json array, you can iterate property by property
and ask if *isJsonArray()* or something like that.
You can also read each value *asText()* which will give you
On Tue, Dec 4, 2018 at 12:27 PM Pankaj Dighe
wrote:
> Thanks for the response. Using TypeReference>() { }
> works fine when I have following json
>
> String jsonString = "{\"personId\": 231, \"percentage\": 2.1212, \"name\":
> \"Name\", " +
> "\"activeDate\":\"26-09-2017 11:00:00\"}";
>
Thanks for the response. Using TypeReference>() { }
works fine when I have following json
String jsonString = "{\"personId\": 231, \"percentage\": 2.1212, \"name\":
\"Name\", " +
"\"activeDate\":\"26-09-2017 11:00:00\"}";
but does not work when I have nested json objects. E.g. : {"a":"
On Tue, Dec 4, 2018 at 10:45 AM Pankaj Dighe
wrote:
> I am trying to deserialize following JSON to map of
>
> String jsonString = "{\"personId\": 231, \"percentage\": 2.1212, \"name\":
> \"Name\", " +
> "\"activeDate\":\"26-09-2017 11:00:00\"}";
>
>
> I am trying to deserialize using fo
We are using Jackson 2.8.5.tr1 (jackson-databind, jackson-core,
jackson-annotations) within our jar file and it works fine using Java 8.
When trying to run our jar file using Java 11, we are getting a runtime
exception -
Caused by: java.lang.ClassNotFoundException:
com.fasterxml.jackson.data
I am trying to deserialize following JSON to map of
String jsonString = "{\"personId\": 231, \"percentage\": 2.1212, \"name\":
\"Name\", " +
"\"activeDate\":\"26-09-2017 11:00:00\"}";
I am trying to deserialize using following code:
new
ObjectMapper()..configure(DeserializationFeatur