| | |
| | | private RealTimeSimulationConfig rtsConfig; |
| | | private static final long MILLIS_OF_ONE_DAY = 86400000; |
| | | |
| | | public String realTimeSimulate(Simu simu) throws IOException { |
| | | public String startSimulation(Simu simu) throws IOException { |
| | | InputStream stream = RealTimeSimulationService.class.getResourceAsStream("/device_info.json"); |
| | | List<DeviceInfo> deviceInfos = mapper.readValue(stream, |
| | | mapper.getTypeFactory().constructCollectionType(List.class, DeviceInfo.class)); |
| | |
| | | String serviceNameDirPath = serviceNameDir.getAbsolutePath(); |
| | | configVo.setTerrain(serviceNameDirPath + File.separator + DEM_TIF); |
| | | configVo.setLanduse(serviceNameDirPath + File.separator + "Landuse.tif"); |
| | | configVo.setEvaporation(config.getEvaporation()); |
| | | File stationFile = new File(serviceNameDir, "Station.tif"); |
| | | if (stationFile.exists()) { |
| | | configVo.setStation(stationFile.getAbsolutePath()); |