From a6415c0c5116172db31fd353032fdfd11ac91544 Mon Sep 17 00:00:00 2001
From: 13693261870 <252740454@qq.com>
Date: 星期五, 01 十一月 2024 20:53:04 +0800
Subject: [PATCH] 1

---
 src/main/java/com/se/simu/service/WaterService.java |   29 +++--------------------------
 1 files changed, 3 insertions(+), 26 deletions(-)

diff --git a/src/main/java/com/se/simu/service/WaterService.java b/src/main/java/com/se/simu/service/WaterService.java
index 07beea4..7d6061a 100644
--- a/src/main/java/com/se/simu/service/WaterService.java
+++ b/src/main/java/com/se/simu/service/WaterService.java
@@ -37,9 +37,9 @@
     /**
      * 鑾峰彇鍏冩暟鎹俊鎭�
      */
-    public byte[] getLayerJson(String serviceName) {
+    public byte[] getson(String serviceName, String json) {
         try {
-            String filePath = config.getOutPath() + File.separator + serviceName + File.separator + "layer.json";
+            String filePath = config.getOutPath() + File.separator + serviceName + File.separator + json;
 
             File dat = new File(filePath);
             if (!dat.exists()) {
@@ -54,6 +54,7 @@
 
             return bytes;
         } catch (Exception ex) {
+            log.error(ex.getMessage(), ex);
             return null;
         }
     }
@@ -101,30 +102,6 @@
         layer.setWaters(new Water(data));
 
         return layer;
-    }
-
-    /**
-     * 鑾峰彇闄嶆按鏇茬嚎鏂囦欢鏇茬嚎鍥�
-     */
-    public byte[] getRainfall(String serviceName) {
-        try {
-            String filePath = config.getOutPath() + File.separator + serviceName + File.separator + "rainfall.json";
-
-            File rainfall = new File(filePath);
-            if (!rainfall.exists()) {
-                return null;
-            }
-
-            byte[] bytes = new byte[(int) rainfall.length()];
-
-            FileInputStream fs = new FileInputStream(filePath);
-            fs.read(bytes);
-            fs.close();
-
-            return bytes;
-        } catch (Exception ex) {
-            return null;
-        }
     }
 
     /**

--
Gitblit v1.9.3