中国开发网: 论坛: 程序员情感CBD: 贴子 178202
品雪: 自己看吧
class String ...{
public static String valueOf(Object obj) {
return (obj == null) ? "null" : obj.toString();
}

public String toString() {
return this;
}

public String concat(String str) {
int otherLen = str.length();
if (otherLen == 0) {
return this;
}
char buf[] = new char[count + otherLen];
getChars(0, count, buf, 0);
str.getChars(0, otherLen, buf, count);
return new String(0, count + otherLen, buf);
}
}

相关信息:


欢迎光临本社区,您还没有登录,不能发贴子。请在 这里登录