http://stackoverflow.com/questions/3131865/why-does-string-valueofnull-throw-a-nullpointerexception
Object o1=new char[3];//ok
char []c2=new Object();//編譯錯誤
public static String valueOf(Object obj) {
return (obj == null) ? "null" : obj.toString();
}
public static String valueOf(char data[]) {
return new String(data);
}