public abstract class CompressionInputStream extends InputStream
Implementations are assumed to be buffered. This permits clients to
reposition the underlying input stream then call resetState()
,
without having to also synchronize client buffers.
Modifier and Type | Field and Description |
---|---|
protected InputStream |
in
The input stream to be compressed.
|
Modifier | Constructor and Description |
---|---|
protected |
CompressionInputStream(InputStream in)
Create a compression input stream that reads
the decompressed bytes from the given stream.
|
Modifier and Type | Method and Description |
---|---|
void |
close() |
abstract int |
read(byte[] b,
int off,
int len)
Read bytes from the stream.
|
abstract void |
resetState()
Reset the decompressor to its initial state and discard any buffered data,
as the underlying stream may have been repositioned.
|
available, mark, markSupported, read, read, reset, skip
protected final InputStream in
protected CompressionInputStream(InputStream in)
in
- The input stream to be compressed.public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
close
in class InputStream
IOException
public abstract int read(byte[] b, int off, int len) throws IOException
read
in class InputStream
IOException
public abstract void resetState() throws IOException
IOException
Copyright © 2010 The Apache Software Foundation