1、ObjectMapper mapper=new ObjectMapper();2、JsonNode node = mapper.readTree(areaData);
JsonNode lastnode=node.get("result").get("1584548").get("result").get(0).get("shops");
List<WetOrFireCheckVo> list = new ArrayList<WetOrFireCheckVo>();try {String areaData = IOUtils.toString(wetOrFireJson.getInputStream(), Charset.forName("UTF-8"));ObjectMapper mapper=new ObjectMapper();JsonNode node = mapper.readTree(areaData);JsonNode wetOrFile = null;if (Objects.equal(1, wetOrFire)) {wetOrFile = node.get("wetCheck");}if (Objects.equal(2, wetOrFire)) {wetOrFile = node.get("fireCheck");}if (wetOrFile != null && wetOrFile.size() > 0) {WetOrFireCheckVo wetOrFireCheckVo = null;for (int i = 0; i < wetOrFile.size(); i++) {JsonNode jsonNode = wetOrFile.get(i);wetOrFireCheckVo.setDescribeInfo(jsonNode.get("describeInfo").asText());wetOrFireCheckVo.setDetail(jsonNode.get("detail").asText());wetOrFireCheckVo.setHappenTime(jsonNode.get("happenTime").asText());wetOrFireCheckVo.setId(jsonNode.get("id").asInt());wetOrFireCheckVo.setModelName(jsonNode.get("modelName").asText());wetOrFireCheckVo.setModelPath(jsonNode.get("modelPath").asText());list.add(wetOrFireCheckVo);}}} catch (IOException e) {e.printStackTrace();}