add methods to StringBuilder and fix logic error in getChars

This commit is contained in:
Joel Dice
2009-08-13 09:02:00 -06:00
parent ae02212dd9
commit 0d7a2fa2bc
2 changed files with 39 additions and 13 deletions

View File

@ -129,10 +129,10 @@ public class StringBuffer implements CharSequence {
sb.setCharAt(index, ch);
}
public synchronized void getChars(int srcOffset, int srcLength, char[] dst,
int dstOffset)
public synchronized void getChars(int srcStart, int srcEnd, char[] dst,
int dstStart)
{
sb.getChars(srcOffset, srcLength, dst, dstOffset);
sb.getChars(srcStart, srcEnd, dst, dstStart);
}
public synchronized String toString() {