Package org.zeroturnaround.zip
Class CloseShieldInputStream
- java.lang.Object
-
- java.io.InputStream
-
- java.io.FilterInputStream
-
- org.zeroturnaround.zip.CloseShieldInputStream
-
- All Implemented Interfaces:
java.io.Closeable,java.lang.AutoCloseable
class CloseShieldInputStream extends java.io.FilterInputStreamFilter stream that prevents the underlying input stream from being closed.It's a simpler version than
org.apache.commons.io.input.CloseShieldInputStreamas it doesn't replace the underlying stream. It's only meant for internal use where we can close aZipInputStreamwithout closing the underlying stream itself.
-
-
Constructor Summary
Constructors Constructor Description CloseShieldInputStream(java.io.InputStream in)Creates aFilterInputStreamby assigning the argumentinto the fieldthis.inso as to remember it for later use.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()-
Methods inherited from class java.io.FilterInputStream
available, mark, markSupported, read, read, read, reset, skip
-
-
-
-
Constructor Detail
-
CloseShieldInputStream
public CloseShieldInputStream(java.io.InputStream in)
Creates aFilterInputStreamby assigning the argumentinto the fieldthis.inso as to remember it for later use.- Parameters:
in- the underlying input stream, ornullif this instance is to be created without an underlying stream.
-
-