利用ObjectMapper,将json数组转List<Map<String,Object>>

通过利用ObjectMapper,将json数组转List<Map<String,Object>>

ObjectMapper objectMapper = new ObjectMapper(); 
List<Map<String,Object>> newMap=objectMapper.readValue("[{id:1,name:'xx'},{id:2,name:'xxx'}]", List.class);
正在加载评论...