// 读取服务器文件内容(TXT文件测试可以)
public List showTxt(String path, String filename){
String filePath = "E:/water/"+path+"/"+filename
FileInputStream fileInputStream = null;
try{
fileInputStream = new FileInputStream(filePath)
} catch (FileNotFoundException e){
e.printStackTrace();
}
InputStreamReader fie = null;
try{
fie = new InputStreamReader(fileInputStream,"GBK");
}catch(UnsupportedEncodingException e){
e.printStackTrace();
}
BufferedReader by = new BufferedReader(fie);
String line = "";
List list = new ArrayList();
try{
while((line=by.readLine())!= null){
list.add(line);
}
}catch(IOException e){
e.printStackTrace();
}
try{
fileInputStream.close();
fie.close();
by.close();
}catch(IOException e){
e.printStackTrace();
}
return list;
}