private void fillBuf ( ) throws IOException { int result = in . read ( buf , 0 , buf . length ) ; if ( result == - 1 ) { throw new EOFException ( ) ; } pos = 0 ; end = result ; }
Reads new input data into the buffer . Call only with pos == end or end == - 1 depending on the desired outcome if the function throws .