Buffer encoded with the LZF format.
See original LZF package
and LZF format for full description.
| Modifier and Type | Class and Description |
|---|---|
| private static enum | LzfDecompressor.
Current state of decompression. |
| Modifier and Type | Field and Description |
|---|---|
| private int | chunkLength
Length of current received chunk of data. |
| private LzfDecompressor. | |
| private ChunkDecoder | decoder
Underlying decoder in use. |
| private boolean | isCompressed
Indicates is this chunk compressed or not. |
| private static final short | MAGIC_NUMBER
Magic number of LZF chunk. |
| private int | originalLength
Original length of current received chunk of data. |
| private BufferRecycler | recycler
Object that handles details of buffer recycling. |
| Access | Constructor and Description |
|---|---|
| private | LzfDecompressor(boolean
If safeInstance)true decoder will use ChunkDecoder that only uses standard JDK access methods,
and should work on all Java platforms and JVMs.
Otherwise decoder will try to use highly optimized ChunkDecoder implementation that uses
Sun JDK's sun. class (which may be included by other JDK's as well).Creates a new LZF decompressor with specified decoding instance. |
| Modifier and Type | Method and Description |
|---|---|
| public void | |
| public Buffer | decompress(Buffer
the in, BufferAllocator Buffer that contains the data to be decompressed.the allocator)BufferAllocator that is used to allocate a new buffer (if needed) to write the
decompressed bytes too.Implements io. Buffer and decompress into a new Buffer that will be
allocated (if needed) from the BufferAllocator.
|
| private Buffer | |
| public boolean | isClosed()
Implements io. true if the decompressor was closed, false otherwise.
|
| public boolean | isFinished()
Implements io. true if the decompressor was finish.
|
| public static Supplier | Returns: the factory.Creates a new LZF decompressor factory with the most optimal available methods for underlying data access. |
| public static Supplier | Returns: the factory.If safeInstance)true decoder will use ChunkDecoder that only uses standard JDK access methods,
and should work on all Java platforms and JVMs.
Otherwise decoder will try to use highly optimized ChunkDecoder implementation that uses
Sun JDK's sun. class (which may be included by other JDK's as well).Creates a new LZF decompressor factory with specified decoding instance. |
| private void |
| chunkLength | back to summary |
|---|---|
| private int chunkLength Length of current received chunk of data. | |
| currentState | back to summary |
|---|---|
| private LzfDecompressor. | |
| decoder | back to summary |
|---|---|
| private ChunkDecoder decoder Underlying decoder in use. | |
| isCompressed | back to summary |
|---|---|
| private boolean isCompressed Indicates is this chunk compressed or not. | |
| MAGIC_NUMBER | back to summary |
|---|---|
| private static final short MAGIC_NUMBER Magic number of LZF chunk. | |
| originalLength | back to summary |
|---|---|
| private int originalLength Original length of current received chunk of data.
It is equal to | |
| recycler | back to summary |
|---|---|
| private BufferRecycler recycler Object that handles details of buffer recycling. | |
| LzfDecompressor | back to summary |
|---|---|
| private LzfDecompressor(boolean safeInstance) Creates a new LZF decompressor with specified decoding instance.
| |
| close | back to summary |
|---|---|
| public void close() Implements io. Doc from io. Close the decompressor. After this method was called
| |
| decompress | back to summary |
|---|---|
| public Buffer decompress(Buffer in, BufferAllocator allocator) throws DecompressionException Implements io. Doc from io. This method will read from the input isFinished() is false
input
| |
| decompress | back to summary |
|---|---|
| private Buffer decompress(BufferAllocator allocator, byte[] inputArray, int offset, int len) throws LZFException | |
| isClosed | back to summary |
|---|---|
| public boolean isClosed() Implements io. Doc from io. Return | |
| isFinished | back to summary |
|---|---|
| public boolean isFinished() Implements io. Doc from io. Returns
| |
| newFactory | back to summary |
|---|---|
| public static Supplier Creates a new LZF decompressor factory with the most optimal available methods for underlying data access.
It will "unsafe" instance if one can be used on current JVM.
It should be safe to call this constructor as implementations are dynamically loaded; however, on some
non-standard platforms it may be necessary to use
| |
| newFactory | back to summary |
|---|---|
| public static Supplier Creates a new LZF decompressor factory with specified decoding instance.
| |
| streamCorrupted | back to summary |
|---|---|
| private void streamCorrupted(String message) | |
| Modifier and Type | Field and Description |
|---|---|
| public static final LzfDecompressor. | |
| public static final LzfDecompressor. | |
| public static final LzfDecompressor. | |
| public static final LzfDecompressor. | |
| public static final LzfDecompressor. | |
| public static final LzfDecompressor. |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static LzfDecompressor. | |
| public static LzfDecompressor. |
| CLOSED | back to summary |
|---|---|
| public static final LzfDecompressor. | |
| CORRUPTED | back to summary |
|---|---|
| public static final LzfDecompressor. | |
| DECOMPRESS_DATA | back to summary |
|---|---|
| public static final LzfDecompressor. | |
| FINISHED | back to summary |
|---|---|
| public static final LzfDecompressor. | |
| INIT_BLOCK | back to summary |
|---|---|
| public static final LzfDecompressor. | |
| INIT_ORIGINAL_LENGTH | back to summary |
|---|---|
| public static final LzfDecompressor. | |
| State | back to summary |
|---|---|
| private State() | |
| valueOf | back to summary |
|---|---|
| public static LzfDecompressor. | |
| values | back to summary |
|---|---|
| public static LzfDecompressor. | |