| | |
| | | } |
| | | } |
| | | |
| | | public String getKeyFrame(DataPo data) throws Exception { |
| | | String cmd = config.getKeyFrameBat() + " " + config.getInPath() + File.separator + data.getInPath() + File.separator + ".save" + File.separator + data.getInPath() + ".sww"; |
| | | |
| | | String str = exec(cmd); |
| | | if (StringHelper.isEmpty(str) || !str.contains("[")) { |
| | | throw new Exception("生成关键帧出错"); |
| | | } |
| | | |
| | | String rs = str.split("\\[", 2)[1].replace("]", "").replace(" ", ""); |
| | | if (StringHelper.isEmpty(rs)) { |
| | | throw new Exception("关键帧为空"); |
| | | } |
| | | |
| | | return rs; |
| | | } |
| | | |
| | | public void copeWaterFiles() { |
| | | // |
| | | } |
| | | |
| | | public void copeDrainFiles() { |
| | | // |
| | | public String copeDrainFiles(DataPo data) throws Exception { |
| | | String time = StringHelper.YMDHMS_FORMAT.format(data.getStartTime()); |
| | | String inPath = config.getInPath() + File.separator + data.getInPath(); |
| | | String sww = inPath + File.separator + ".save" + File.separator + data.getInPath() + ".sww"; |
| | | |
| | | String cmd = config.getSww2tifBat() + " " + sww + " '" + time + "' " + data.getEpsg() + " " + inPath; |
| | | |
| | | return exec(cmd); |
| | | } |
| | | } |