Home | History | Annotate | Download | only in number

Lines Matching refs:length

35     private int length;
45 length = 0;
53 chars = Arrays.copyOf(source.chars, source.chars.length);
54 fields = Arrays.copyOf(source.fields, source.fields.length);
56 length = source.length;
60 public int length() {
61 return length;
65 return Character.codePointCount(this, 0, length());
71 assert index < length;
77 assert index < length;
82 if (length == 0) {
85 return Character.codePointAt(chars, zero, zero + length);
89 if (length == 0) {
92 return Character.codePointBefore(chars, zero + length, zero);
96 return Character.codePointAt(chars, zero + index, zero + length);
105 length = 0;
115 return insertCodePoint(length, codePoint, field);
136 * @return The number of chars added, which is the length of CharSequence.
139 return insert(length, sequence, field);
145 * @return The number of chars added, which is the length of CharSequence.
148 if (sequence.length() == 0) {
151 } else if (sequence.length() == 1) {
156 return insert(index, sequence, 0, sequence.length(), field);
164 * @return The number of chars added, which is the length of CharSequence.
178 * the specified field array, which must have the same length as chars.
180 * @return The number of chars added, which is the length of the char array.
183 return insert(length, chars, fields);
188 * fields in the specified field array, which must have the same length as chars.
190 * @return The number of chars added, which is the length of the char array.
193 assert fields == null || chars.length == fields.length;
194 int count = chars.length;
208 * @return The number of chars added, which is the length of the other {@link NumberStringBuilder}.
211 return insert(length, other);
217 * @return The number of chars added, which is the length of the other {@link NumberStringBuilder}.
223 int count = other.length;
249 length += count;
251 } else if (index == length && zero + length + count < getCapacity()) {
253 length += count;
254 return zero + length - count;
267 if (length + count > oldCapacity) {
268 int newCapacity = (length + count) * 2;
269 int newZero = newCapacity / 2 - (length + count) / 2;
277 System.arraycopy(oldChars, oldZero + index, newChars, newZero + index + count, length - index);
279 System.arraycopy(oldFields, oldZero + index, newFields, newZero + index + count, length - index);
284 length += count;
286 int newZero = oldCapacity / 2 - (length + count) / 2;
290 System.arraycopy(oldChars, oldZero, oldChars, newZero, length);
291 System.arraycopy(oldChars, newZero + index, oldChars, newZero + index + count, length - index);
292 System.arraycopy(oldFields, oldZero, oldFields, newZero, length);
293 System.arraycopy(oldFields, newZero + index, oldFields, newZero + index + count, length - index);
296 length += count;
302 return chars.length;
307 if (start < 0 || end > length || end < start) {
312 other.length = end - start;
324 return new String(chars, zero, length);
357 for (int i = zero; i < zero + length; i++) {
370 return Arrays.copyOfRange(chars, zero, zero + length);
375 return Arrays.copyOfRange(fields, zero, zero + length);
384 if (chars.length != length)
386 if (fields.length != length)
388 for (int i = 0; i < length; i++) {
403 if (length != other.length)
405 for (int i = 0; i < length; i++) {
456 for (int i = zero; i <= zero + length; i++) {
457 Field _field = (i < zero + length) ? fields[i] : null;
485 for (int i = 0; i < length; i++) {
499 as.addAttribute(current, current, currentStart, length);