diff --git a/src/META-INF/MANIFEST.MF b/src/META-INF/MANIFEST.MF new file mode 100644 index 0000000..807b30e --- /dev/null +++ b/src/META-INF/MANIFEST.MF @@ -0,0 +1,3 @@ +Manifest-Version: 1.0 +Main-Class: com.qy.ui.AppMain + diff --git a/src/com/qy/ui/ChuanShanJiaUi.java b/src/com/qy/ui/ChuanShanJiaUi.java index 891c832..ee8277f 100644 --- a/src/com/qy/ui/ChuanShanJiaUi.java +++ b/src/com/qy/ui/ChuanShanJiaUi.java @@ -64,7 +64,7 @@ public class ChuanShanJiaUi { } }else{ append("没有找到穿山甲demo,请将穿山甲demo放置在 input"+File.separator+"csjDemo文件夹中"); - csjDemo.mkdirs(); + csjPath.mkdirs(); } } } diff --git a/src/com/qy/utils/Tools.java b/src/com/qy/utils/Tools.java index cac2b49..7c47496 100755 --- a/src/com/qy/utils/Tools.java +++ b/src/com/qy/utils/Tools.java @@ -1,14 +1,7 @@ package com.qy.utils; -import java.io.BufferedReader; -import java.io.File; -import java.io.FileInputStream; -import java.io.FileNotFoundException; -import java.io.FileOutputStream; -import java.io.FileReader; -import java.io.IOException; -import java.io.InputStream; -import java.io.OutputStream; +import java.io.*; +import java.nio.charset.StandardCharsets; import java.util.Random; import org.json.JSONObject; @@ -130,9 +123,9 @@ public class Tools { e.printStackTrace(); } } else { + String tmp, str = ""; try { - reader = new BufferedReader(new FileReader(file)); - String tmp, str = ""; + reader = new BufferedReader( new InputStreamReader(new FileInputStream(file), StandardCharsets.UTF_8)); while ((tmp = reader.readLine()) != null) { str += tmp; } @@ -140,6 +133,7 @@ public class Tools { } catch (Exception e) { // TODO Auto-generated catch block e.printStackTrace(); + System.out.println(str); } } return json;