com.partnersoft.v3x.gui
Class ProgressTrackingInputStream

java.lang.Object
  extended by java.io.InputStream
      extended by java.io.FilterInputStream
          extended by com.partnersoft.v3x.io.CountingInputStream
              extended by com.partnersoft.v3x.gui.ProgressTrackingInputStream
All Implemented Interfaces:
java.io.Closeable

public class ProgressTrackingInputStream
extends CountingInputStream

An input stream that notifies SystemProgressMeters of input progress.


Field Summary
 
Fields inherited from class java.io.FilterInputStream
in
 
Constructor Summary
ProgressTrackingInputStream(java.io.File filet)
          Handy; provides a buffered tracking input stream for the given file, and goes ahead and sets the max on the file meter to the file length.
ProgressTrackingInputStream(java.io.InputStream in)
           
ProgressTrackingInputStream(java.io.InputStream in, boolean verbose)
           
ProgressTrackingInputStream(java.io.InputStream in, java.io.File filet)
           
 
Method Summary
 void bytesWereRead(int byteCount)
          Override this to be notified of each batch of data.
 
Methods inherited from class com.partnersoft.v3x.io.CountingInputStream
getByteCount, isVerbose, mark, read, read, read, reset, setVerbose, skip
 
Methods inherited from class java.io.FilterInputStream
available, close, markSupported
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ProgressTrackingInputStream

public ProgressTrackingInputStream(java.io.File filet)
                            throws java.io.IOException
Handy; provides a buffered tracking input stream for the given file, and goes ahead and sets the max on the file meter to the file length.

Throws:
java.io.IOException

ProgressTrackingInputStream

public ProgressTrackingInputStream(java.io.InputStream in,
                                   java.io.File filet)
                            throws java.io.IOException
Throws:
java.io.IOException

ProgressTrackingInputStream

public ProgressTrackingInputStream(java.io.InputStream in)

ProgressTrackingInputStream

public ProgressTrackingInputStream(java.io.InputStream in,
                                   boolean verbose)
Method Detail

bytesWereRead

public void bytesWereRead(int byteCount)
Description copied from class: CountingInputStream
Override this to be notified of each batch of data.

Overrides:
bytesWereRead in class CountingInputStream