默认情况下,JAVA中的字符串采用UTF-8(Unipre)格式,但是当您要写下来时,则需要指定编码
try { FileOutputStream fos = new FileOutputStream("test.txt"); Writer out = new OutputStreamWriter(fos, "UTF8"); out.write(str); out.close();} catch (IOException e) { e.printStackTrace();}参考:http :
//download.oracle.com/javase/tutorial/i18n/text/stream.html



