263 |
{ |
{ |
264 |
if (srcOffset < 0 || srcEnd > count || srcEnd < srcOffset) |
if (srcOffset < 0 || srcEnd > count || srcEnd < srcOffset) |
265 |
throw new StringIndexOutOfBoundsException(); |
throw new StringIndexOutOfBoundsException(); |
266 |
System.arraycopy(value, srcOffset, dst, dstOffset, srcEnd - srcOffset); |
VMSystem.arraycopy(value, srcOffset, dst, dstOffset, srcEnd - srcOffset); |
267 |
} |
} |
268 |
|
|
269 |
/** |
/** |
334 |
{ |
{ |
335 |
int len = stringBuffer.count; |
int len = stringBuffer.count; |
336 |
ensureCapacity_unsynchronized(count + len); |
ensureCapacity_unsynchronized(count + len); |
337 |
System.arraycopy(stringBuffer.value, 0, value, count, len); |
VMSystem.arraycopy(stringBuffer.value, 0, value, count, len); |
338 |
count += len; |
count += len; |
339 |
} |
} |
340 |
return this; |
return this; |
374 |
if (offset < 0 || count < 0 || offset > data.length - count) |
if (offset < 0 || count < 0 || offset > data.length - count) |
375 |
throw new StringIndexOutOfBoundsException(); |
throw new StringIndexOutOfBoundsException(); |
376 |
ensureCapacity_unsynchronized(this.count + count); |
ensureCapacity_unsynchronized(this.count + count); |
377 |
System.arraycopy(data, offset, value, this.count, count); |
VMSystem.arraycopy(data, offset, value, this.count, count); |
378 |
this.count += count; |
this.count += count; |
379 |
return this; |
return this; |
380 |
} |
} |
483 |
// This will unshare if required. |
// This will unshare if required. |
484 |
ensureCapacity_unsynchronized(count); |
ensureCapacity_unsynchronized(count); |
485 |
if (count - end != 0) |
if (count - end != 0) |
486 |
System.arraycopy(value, end, value, start, count - end); |
VMSystem.arraycopy(value, end, value, start, count - end); |
487 |
count -= end - start; |
count -= end - start; |
488 |
return this; |
return this; |
489 |
} |
} |
526 |
ensureCapacity_unsynchronized(count + delta); |
ensureCapacity_unsynchronized(count + delta); |
527 |
|
|
528 |
if (delta != 0 && end < count) |
if (delta != 0 && end < count) |
529 |
System.arraycopy(value, end, value, end + delta, count - end); |
VMSystem.arraycopy(value, end, value, end + delta, count - end); |
530 |
|
|
531 |
str.getChars(0, len, value, start); |
str.getChars(0, len, value, start); |
532 |
count += delta; |
count += delta; |
613 |
|| str_offset < 0 || str_offset > str.length - len) |
|| str_offset < 0 || str_offset > str.length - len) |
614 |
throw new StringIndexOutOfBoundsException(); |
throw new StringIndexOutOfBoundsException(); |
615 |
ensureCapacity_unsynchronized(count + len); |
ensureCapacity_unsynchronized(count + len); |
616 |
System.arraycopy(value, offset, value, offset + len, count - offset); |
VMSystem.arraycopy(value, offset, value, offset + len, count - offset); |
617 |
System.arraycopy(str, str_offset, value, offset, len); |
VMSystem.arraycopy(str, str_offset, value, offset, len); |
618 |
count += len; |
count += len; |
619 |
return this; |
return this; |
620 |
} |
} |
653 |
str = "null"; |
str = "null"; |
654 |
int len = str.count; |
int len = str.count; |
655 |
ensureCapacity_unsynchronized(count + len); |
ensureCapacity_unsynchronized(count + len); |
656 |
System.arraycopy(value, offset, value, offset + len, count - offset); |
VMSystem.arraycopy(value, offset, value, offset + len, count - offset); |
657 |
str.getChars(0, len, value, offset); |
str.getChars(0, len, value, offset); |
658 |
count += len; |
count += len; |
659 |
return this; |
return this; |
704 |
if (offset < 0 || offset > count) |
if (offset < 0 || offset > count) |
705 |
throw new StringIndexOutOfBoundsException(offset); |
throw new StringIndexOutOfBoundsException(offset); |
706 |
ensureCapacity_unsynchronized(count + 1); |
ensureCapacity_unsynchronized(count + 1); |
707 |
System.arraycopy(value, offset, value, offset + 1, count - offset); |
VMSystem.arraycopy(value, offset, value, offset + 1, count - offset); |
708 |
value[offset] = ch; |
value[offset] = ch; |
709 |
count++; |
count++; |
710 |
return this; |
return this; |
900 |
: value.length); |
: value.length); |
901 |
minimumCapacity = (minimumCapacity < max ? max : minimumCapacity); |
minimumCapacity = (minimumCapacity < max ? max : minimumCapacity); |
902 |
char[] nb = new char[minimumCapacity]; |
char[] nb = new char[minimumCapacity]; |
903 |
System.arraycopy(value, 0, nb, 0, count); |
VMSystem.arraycopy(value, 0, nb, 0, count); |
904 |
value = nb; |
value = nb; |
905 |
shared = false; |
shared = false; |
906 |
} |
} |