@InterfaceAudience.Public @InterfaceStability.Evolving public abstract class CompressionOutputStream extends OutputStream
| Modifier and Type | Field and Description | 
|---|---|
protected OutputStream | 
out
The output stream to be compressed. 
 | 
| Modifier | Constructor and Description | 
|---|---|
protected  | 
CompressionOutputStream(OutputStream out)
Create a compression output stream that writes
 the compressed bytes to the given stream. 
 | 
| Modifier and Type | Method and Description | 
|---|---|
void | 
close()  | 
abstract void | 
finish()
Finishes writing compressed data to the output stream 
 without closing the underlying stream. 
 | 
void | 
flush()  | 
abstract void | 
resetState()
Reset the compression to the initial state. 
 | 
abstract void | 
write(byte[] b,
     int off,
     int len)
Write compressed bytes to the stream. 
 | 
write, writeprotected final OutputStream out
protected CompressionOutputStream(OutputStream out)
out - public void close() throws IOException
close in interface Closeableclose in interface AutoCloseableclose in class OutputStreamIOExceptionpublic void flush() throws IOException
flush in interface Flushableflush in class OutputStreamIOExceptionpublic abstract void write(byte[] b, int off, int len) throws IOException
write in class OutputStreamIOExceptionpublic abstract void finish() throws IOException
IOExceptionpublic abstract void resetState() throws IOException
IOExceptionCopyright © 2017 Apache Software Foundation. All rights reserved.