public class SnzInputStream extends FilterInputStream
This class implements a stream filter for reading compressed data in the SNZ file format.
The data format is compatible to the snzip tool, which is available as a patch to the official Snappy source code.
in| Constructor and Description |
|---|
SnzInputStream(InputStream in)
Creates a new SnzInputStream, reading from the provided InputStream
in. |
| Modifier and Type | Method and Description |
|---|---|
int |
getBlockSize()
Returns the block size of the snz stream.
|
int |
read()
Reads a single byte from the uncompressed stream.
|
int |
read(byte[] b)
Fills the byte array with data from the uncompressed stream.
|
int |
read(byte[] b,
int offset,
int length)
Fills the byte array with data from the uncompressed stream starting
at the specified
offset and no more than length bytes. |
available, close, mark, markSupported, reset, skippublic SnzInputStream(InputStream in)
in.in - public int getBlockSize()
throws IOException
IOExceptionpublic int read()
throws IOException
read in class FilterInputStreamFormatViolationException - if the input data is invalidIOExceptionpublic int read(byte[] b)
throws IOException
read in class FilterInputStreamFormatViolationException - if the input data is invalidIOExceptionpublic int read(byte[] b,
int offset,
int length)
throws IOException
offset and no more than length bytes.read in class FilterInputStreamb - destination arrayoffset - offset into the byte array, on which the data is writtenFormatViolationException - if the input data is invalidIOExceptionCopyright © 2014 AVAST Software. All Rights Reserved.