java.lang.Object
java.io.OutputStream
java.io.FilterOutputStream
com.aoapps.hodgepodge.io.DontCloseOutputStream
- All Implemented Interfaces:
NoClose
,Closeable
,Flushable
,AutoCloseable
Deprecated.
Wraps an OutputStream to protect it from close calls. This is useful for at least
GZIPOutputStream where the native resources of the GZIPOutputStream need to be released
using the close call while the underlying stream is left intact.
- Author:
- AO Industries, Inc.
-
Field Summary
Fields inherited from class java.io.FilterOutputStream
out
-
Constructor Summary
-
Method Summary
Methods inherited from class java.io.FilterOutputStream
flush, write, write
Methods inherited from class java.io.OutputStream
nullOutputStream
-
Constructor Details
-
DontCloseOutputStream
Deprecated.
-
-
Method Details
-
write
Deprecated.- Overrides:
write
in classFilterOutputStream
- Throws:
IOException
-
close
public void close()Deprecated.Does nothing on close to protect the wrapped OutputStream.- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Specified by:
close
in interfaceNoClose
- Overrides:
close
in classFilterOutputStream
-
NoCloseOutputStream
instead