protected void update ( long readBytes ) throws IOException { if ( progressListener . isAborted ( ) ) { throw new IOException ( "Reading Cancelled by ProgressListener" ) ; } this . bytesRead += readBytes ; int step = ( int ) ( bytesRead / stepSize ) ; if ( step > lastStep ) { lastStep = step ; progressListener . updateProgress ( step , stepNumber ) ; } }
This method is called by the actual input stream method to provide feedback about the number of read bytes .