FastJson序列化

it2022-05-07  0

String post = HttpClientUtils.httpPost(martinUrl + "index/status",new HashMap<>()); JSONObject object = JSON.parseObject(post); String jsonString = object.getJSONArray("data").toJSONString(); List<MartinResVo> list = JSON.parseArray(jsonString, MartinResVo.class); list.forEach(x->{ x.setChineseDesc(IndexNameEnum.getDescByAlias(x.getIndexAlias())); }); res.setData(list);

转载于:https://www.cnblogs.com/BBchao/p/9516165.html


最新回复(0)