InputStream that may be GZIP compressed or not.
This stream assumes that the GZIP header is unique to the raw content.
That is, one should not use this on a stream that may have raw data
in the begining of the stream that collides with the GZIP header.
In the case of Ion binary, Ion text, and XML, a GZIP stream is unambiguous
from them.
| Modifier and Type | Field and Description |
|---|---|
| pack-priv static final byte[] | GZIP_HEADER
GZIP magic cookie. |
| Access | Constructor and Description |
|---|---|
| pack-priv | GzipOrRawInputStream(final InputStream
The input stream to wrap. raw)Wraps the given stream determining based on the GZIP header whether or not the stream is compressed and should be dynamically de-compressed. |
| pack-priv | GzipOrRawInputStream(final InputStream
The input stream to wrap. raw, final int internal buffer size to use for decompression. bufferSize)Wraps the given stream determining based on the GZIP header whether or not the stream is compressed and should be dynamically de-compressed. |
| GZIP_HEADER | back to summary |
|---|---|
| pack-priv static final byte[] GZIP_HEADER GZIP magic cookie. | |
| GzipOrRawInputStream | back to summary |
|---|---|
| pack-priv GzipOrRawInputStream(final InputStream raw) throws IOException Wraps the given stream determining based on the GZIP header whether or not the stream is compressed and should be dynamically de-compressed.
| |
| GzipOrRawInputStream | back to summary |
|---|---|
| pack-priv GzipOrRawInputStream(final InputStream raw, final int bufferSize) throws IOException Wraps the given stream determining based on the GZIP header whether or not the stream is compressed and should be dynamically de-compressed.
| |