org.apache.james.util.stream
Class DisposeOnCloseInputStream

java.lang.Object
  extended by java.io.InputStream
      extended by java.io.FilterInputStream
          extended by org.apache.james.util.stream.DisposeOnCloseInputStream
All Implemented Interfaces:
java.io.Closeable

public class DisposeOnCloseInputStream
extends java.io.FilterInputStream

FilterInputStream which dispose wrapped InputStream after close is called


Field Summary
 
Fields inherited from class java.io.FilterInputStream
in
 
Constructor Summary
protected DisposeOnCloseInputStream(java.io.InputStream in)
           
 
Method Summary
 void close()
          Close the wrapped InputStream and dispose it
 
Methods inherited from class java.io.FilterInputStream
available, mark, markSupported, read, read, read, reset, skip
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DisposeOnCloseInputStream

protected DisposeOnCloseInputStream(java.io.InputStream in)
Method Detail

close

public void close()
           throws java.io.IOException
Close the wrapped InputStream and dispose it

Specified by:
close in interface java.io.Closeable
Overrides:
close in class java.io.FilterInputStream
Throws:
java.io.IOException


Copyright © 2002-2010 The Apache Software Foundation. All Rights Reserved.