| | |
| | | List<GeLayer> layers = getLayers(token, db); |
| | | queryData(token, db, layers); |
| | | createShps(basePath, layers); |
| | | |
| | | |
| | | createZoneShp(basePath, data, db.getSpatialReference()); |
| | | if (data.getPid() > 0) { |
| | | createFloodShp(basePath, data, db.getSpatialReference()); |
| | |
| | | } |
| | | |
| | | private void createZoneShp(String basePath, DataPo data, SpatialReference sr) { |
| | | String filePath = basePath + File.separator + ""; |
| | | ShpHelper.createShp(filePath, sr, data.getMinx(), data.getMiny(), data.getMaxx(), data.getMaxy()); |
| | | String filePath = basePath + File.separator + config.getZoneName(); |
| | | ShpHelper.createShp(filePath,null, sr, data.getMinx(), data.getMiny(), data.getMaxx(), data.getMaxy()); |
| | | } |
| | | |
| | | private void createFloodShp(String basePath, DataPo data, SpatialReference sr) { |
| | | // |
| | | String filePath = basePath + File.separator + config.getBarrierName(); |
| | | Map<String, Object> map = new HashMap<>(); |
| | | map.put("height", data.getFloodHeight()); |
| | | map.put("type", data.getFloodType()); |
| | | |
| | | ShpHelper.createShp(filePath, map, sr, data.getFloodMinx(), data.getFloodMiny(), data.getFloodMaxx(), data.getFloodMaxy()); |
| | | } |
| | | |
| | | public void copeDem(String token, DataPo data) throws Exception { |