我知道是编码问题,但是非常奇怪的是我把那个工程转换成java的就一切正常,然后添加aspectj特性以后就不对了,我尝试过很多方法 //System.setProperty("file.encoding","GBK");
System.out.println(System.getProperty("file.encoding"));
System.out.println("你好你好");
System.out.println("gbk: " + new String("你好".getBytes("gbk")));
System.out.println("gb2312: " + new String("你好".getBytes("gb2312")));
System.out.println("gb18030: " + new String("你好".getBytes("gb18030")));
System.out.println("utf-8: " + new String("你好".getBytes("utf-8")));
System.out.println("utf-16: " + new String("你好".getBytes("utf-16")));
System.out.println("unicode: " + new String("你好".getBytes("unicode")));
System.out.println("big5: " + new String("你好".getBytes("big5")));
String s1="你好";
String s2 = new String(s1.getBytes("gbk"),"gb18030");
System.out.println("s2: " + s2);
但是这些都没有用,我都不知道还能怎么办了,你能帮帮我吗?