Files
jshERP/WebRoot/js/StringBuffer.js
季圣华 3d34abebd2
2016-10-30 14:23:49 +08:00

11 lines
282 B
JavaScript

function StringBuffer() {
this.array = new Array();
}
StringBuffer.prototype.append = function(value) {
this.array[this.array.length] = value;
return this;
}
StringBuffer.prototype.toString = function() {
var _string = this.array.join("");
return _string;
}