@Test public void position() { assertThat(CharBuffer.fromString("").position(), is(0)); CharBuffer buffer = CharBuffer.fromString("..."); assertThat(buffer.position(), is(0)); assertThat(buffer.get(), is('.')); assertThat(buffer.position(), is(1)); assertThat(buffer.get(), is('.')); assertThat(buffer.position(), is(2)); assertThat(buffer.get(), is('.')); assertThat(buffer.position(), is(3)); }
int position() { return position; }
CharBuffer { int position() { return position; } }
CharBuffer { int position() { return position; } private  CharBuffer(char[] cs); }
CharBuffer { int position() { return position; } private  CharBuffer(char[] cs); @Override String toString(); }
CharBuffer { int position() { return position; } private  CharBuffer(char[] cs); @Override String toString(); public char[] cs; public int position; }