String(byte[] bytes)
Constructs a new String by decoding the specified array of bytes using the platform's default charset.关于构造一个字节数组的String对象,文档里面的这个解说看得不是很明白,有没有哪位兄弟举例介绍介绍?
Constructs a new String by decoding the specified array of bytes using the platform's default charset.关于构造一个字节数组的String对象,文档里面的这个解说看得不是很明白,有没有哪位兄弟举例介绍介绍?
意思是
char c=new char[10];
String s=new String(c);如果在简体中文的操作系统上,上面两行等效于
char c=new char[10];
String s=new String(c,"GB2312");