MutableCharArray implements CharSequence, Cloneable { public int length() { return length; } MutableCharArray();  MutableCharArray(CharSequence seq);  MutableCharArray(char[] buffer);  MutableCharArray(char[] buffer, int start, int length); void reset(CharSequence seq); void reset(char[] buffer); void reset(char[] buffer, int start, int length); char[] getBuffer(); int getStart(); final char charAt(final int index); int length(); MutableCharArray subSequence(int start, int end); @Override String toString(); @Override int hashCode(); @Override boolean equals(Object other); static final int hashCode(final char[] buffer, int start, int length); MutableCharArray clone(); char[] toArray();  }
@Test public void testLength() { MutableCharArray seq = new MutableCharArray("1234"); assertEquals(4, seq.length()); seq = new MutableCharArray("1234".toCharArray(), 1, 2); assertEquals(2, seq.length()); }