public abstract class CompressedStream4D extends Stream
| Modifier and Type | Field and Description |
|---|---|
protected java.lang.Object |
compressedStream |
static int |
DEFLATE |
protected static int |
GZIP_COMPRESSION |
static int |
INFLATE |
protected int |
mode |
protected byte[] |
streamBuffer |
protected static int |
ZIP_COMPRESSION |
protected static int |
ZLIB_COMPRESSION |
skipBuffer| Modifier | Constructor and Description |
|---|---|
protected |
CompressedStream4D(Stream stream,
int mode,
int compressionType) |
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Closes this I/O connection, releasing any associated resources.
|
protected java.lang.Object |
createDeflate(Stream stream,
int compressionType) |
protected java.lang.Object |
createInflate(Stream stream) |
protected void |
finalize() |
int |
readBytes(byte[] buf,
int start,
int count)
Reads bytes from the stream.
|
int |
writeBytes(byte[] buf,
int start,
int count)
Writes bytes to the stream.
|
asInputStream, asOutputStream, asStream, asStream, skipBytes, wrapInputStream, wrapInputStreamToStream, write, writeBytes, writeBytes, writeBytesprotected java.lang.Object compressedStream
protected int mode
protected byte[] streamBuffer
public static final int DEFLATE
public static final int INFLATE
protected static final int ZLIB_COMPRESSION
protected static final int GZIP_COMPRESSION
protected static final int ZIP_COMPRESSION
protected CompressedStream4D(Stream stream, int mode, int compressionType)
protected java.lang.Object createInflate(Stream stream)
protected java.lang.Object createDeflate(Stream stream, int compressionType)
public int readBytes(byte[] buf,
int start,
int count)
throws IOException,
ZipException
StreamreadBytes in class Streambuf - the byte array to read data intostart - the start position in the arraycount - the number of bytes to readIOExceptionZipExceptionpublic int writeBytes(byte[] buf,
int start,
int count)
throws IOException
StreamIOException if an error prevented the write
operation from occurring.writeBytes in class Streambuf - the byte array to write data fromstart - the start position in the byte arraycount - the number of bytes to writeIOExceptionpublic void close()
throws IOException
close in interface java.io.Closeableclose in interface java.lang.AutoCloseableIOException - If an I/O error occurs.protected void finalize()
finalize in class java.lang.Object