[AppleScript] 纯文本查看 复制代码
public String concat(String string) {
if (string.count > 0 && count > 0) {
char[] buffer = new char[count + string.count];
System.arraycopy(value, offset, buffer, 0, count);
System.arraycopy(string.value, string.offset, buffer, count, string.count);
return new String(0, buffer.length, buffer);
}
return count == 0 ? string : this;
}
[AppleScript] 纯文本查看 复制代码
/**
* Adds the specified string to the end of this buffer.
* <p>
* If the specified string is {@code null} the string {@code "null"} is
* appended, otherwise the contents of the specified string is appended.
*
* @param string
* the string to append (may be null).
* @return this StringBuffer.
*/
public synchronized StringBuffer append(String string) {
append0(string);
return this;
}