1 Clazz.declarePackage ("JU");
2 c$ = Clazz.decorateAsClass (function () {
5 Clazz.instantialize (this, arguments);
7 Clazz.makeConstructor (c$,
12 c$.newN = Clazz.defineMethod (c$, "newN",
17 c$.newS = Clazz.defineMethod (c$, "newS",
24 Clazz.defineMethod (c$, "append",
30 Clazz.defineMethod (c$, "appendC",
36 Clazz.defineMethod (c$, "appendI",
42 Clazz.defineMethod (c$, "appendB",
48 Clazz.defineMethod (c$, "appendF",
52 if (sf.indexOf(".") < 0 && sf.indexOf("e") < 0)
57 Clazz.defineMethod (c$, "appendD",
61 if (sf.indexOf(".") < 0 && sf.indexOf("e") < 0)
66 Clazz.defineMethod (c$, "appendSB",
72 Clazz.defineMethod (c$, "appendO",
76 this.s += data.toString();
79 Clazz.defineMethod (c$, "appendCB",
80 function (cb, off, len) {
82 for (var i = len,j=off; --i >= 0;)
85 Clazz.overrideMethod (c$, "toString",
90 Clazz.defineMethod (c$, "length",
95 Clazz.defineMethod (c$, "indexOf",
98 return this.s.indexOf(s);
100 Clazz.defineMethod (c$, "charAt",
103 return this.s.charAt(i);
105 Clazz.defineMethod (c$, "charCodeAt",
108 return this.s.charCodeAt(i);
110 Clazz.defineMethod (c$, "setLength",
113 this.s = this.s.substring(0, n);
115 Clazz.defineMethod (c$, "lastIndexOf",
118 return this.s.lastIndexOf(s);
120 Clazz.defineMethod (c$, "indexOf2",
123 return this.s.indexOf(s, i);
125 Clazz.defineMethod (c$, "substring",
128 return this.s.substring(i);
130 Clazz.defineMethod (c$, "substring2",
133 return this.s.substring(i, j);
135 Clazz.defineMethod (c$, "toBytes",
136 function (off, len) {
137 if (len < 0) len = this.length () - off;
138 var b = Clazz.newByteArray (len, 0);
139 for (var i = off + len, j = i - off; --i >= off; ) b[--j] = (this.charAt (i)).charCodeAt (0);
143 Clazz.defineMethod (c$, "replace",
144 function (start, end, str) {
146 this.s = this.s.substring(0, start) + str + this.s.substring(end);
148 Clazz.defineMethod (c$, "insert",
149 function (offset, str) {
150 this.replace (offset, offset, str);