com.calitha.io
Class NoCloseInputStream
java.lang.Object
java.io.InputStream
java.io.FilterInputStream
com.calitha.io.NoCloseInputStream
- All Implemented Interfaces:
- Closeable
public class NoCloseInputStream
- extends FilterInputStream
A NoCloseInputStream is used in the case where calls to close an input stream
must be ignored.
This class is necessary for reading XML files from a zip input stream, because
the parser kept closing the stream.
- Author:
- Robert van Loenhout
|
Constructor Summary |
NoCloseInputStream(InputStream input)
Creates a new FilterInputStream where most calls are forwarded to the
input stream passed to it. |
|
Method Summary |
void |
close()
This method ignores when close is called. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
NoCloseInputStream
public NoCloseInputStream(InputStream input)
- Creates a new FilterInputStream where most calls are forwarded to the
input stream passed to it.
- Parameters:
input - input stream
close
public void close()
- This method ignores when close is called.
- Specified by:
close in interface Closeable- Overrides:
close in class FilterInputStream