공부
[Spring] ObjectMapper.readValue(json, object : TypeReference<String>() {})
승가비
2022. 6. 6. 04:22
728x90
inline fun <reified T> ObjectMapper.readValue(json: String): T = readValue(json, object : TypeReference<T>(){})
How do I deserialize JSON into a List<SomeType> with Kotlin + Jackson
What is the correct syntax to deserialize the following JSON: [ { "id" : "1", "name" : "Blues" }, { "id" : "0", "name" : "Rock" } ] I tried: //Works OK val dtos = mapper.readValue(json,
stackoverflow.com
728x90