Quantcast
Channel: User Chris - Stack Overflow
Viewing all articles
Browse latest Browse all 39

Answer by Chris for Jackson deserialise JSON with many dynamic nodes

$
0
0

Yeah was clearly overthinking it. As @chrylis suggested a Map was the right direction to go in.

Simple as:

final TypeReference<HashMap<String, Language>> typeRef = new TypeReference<>() {};final HashMap<String, Language> hashMap = objectMapper.readValue(new ClassPathResource("data/languages.json").getFile(), typeRef);

Viewing all articles
Browse latest Browse all 39

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>