I have a HashMap
object which I want to convert to JsonNode
tree using com.fasterxml.jackson.databind.ObjectMapper
. What is the best way to do it?
I found the following code but since I don't know the Jackson API well, I wonder if there are some better ways.
mapper.reader().readTree(mapper.writeValueAsString(hashmap))