设置默认的Java字符编码?
-Dfile.encoding=whatever
System.setProperty("file.encoding", "UTF-8"); System.setProperty("file.encoding", "UTF-8");
byte inbytes[] = new byte[1024];
FileInputStream fis = new FileInputStream("response.txt");
fis.read(inbytes);
FileOutputStream fos = new FileOutputStream("response-2.txt");
String in = new String(inbytes, "UTF8");
fos.write(in.getBytes());
牧羊人nacy
ITMISS
扬帆大鱼
随时随地看视频慕课网APP
相关分类