org.apache.commons.vfs.provider
Class DefaultFileContent.FileContentInputStream

java.lang.Object
  extended by java.io.InputStream
      extended by java.io.FilterInputStream
          extended by java.io.BufferedInputStream
              extended by org.apache.commons.vfs.util.MonitorInputStream
                  extended by org.apache.commons.vfs.provider.DefaultFileContent.FileContentInputStream
All Implemented Interfaces:
java.io.Closeable
Enclosing class:
DefaultFileContent

private final class DefaultFileContent.FileContentInputStream
extends MonitorInputStream

An input stream for reading content. Provides buffering, and end-of-stream monitoring.


Field Summary
private  FileObject file
           
 
Fields inherited from class java.io.BufferedInputStream
buf, marklimit, markpos, pos
 
Fields inherited from class java.io.FilterInputStream
in
 
Constructor Summary
DefaultFileContent.FileContentInputStream(FileObject file, java.io.InputStream instr)
           
 
Method Summary
 void close()
          Closes this input stream.
protected  void onClose()
          Called after the stream has been closed.
 
Methods inherited from class org.apache.commons.vfs.util.MonitorInputStream
getCount, read, read
 
Methods inherited from class java.io.BufferedInputStream
available, mark, markSupported, reset, skip
 
Methods inherited from class java.io.FilterInputStream
read
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

file

private final FileObject file
Constructor Detail

DefaultFileContent.FileContentInputStream

DefaultFileContent.FileContentInputStream(FileObject file,
                                          java.io.InputStream instr)
Method Detail

close

public void close()
           throws FileSystemException
Closes this input stream.

Specified by:
close in interface java.io.Closeable
Overrides:
close in class MonitorInputStream
Throws:
FileSystemException

onClose

protected void onClose()
                throws java.io.IOException
Called after the stream has been closed.

Overrides:
onClose in class MonitorInputStream
Throws:
java.io.IOException