Decoder for the "gzip" content encoding.
This decoder inflates gzip compressed data, and has been optimized for async usage with minimal data copies.
| Modifier and Type | Class and Description |
|---|---|
| private static enum |
| Modifier and Type | Field and Description |
|---|---|
| private final int | |
| private byte | |
| private RetainableByteBuffer | |
| private final List | |
| private Inflater | |
| private CompressionPool | |
| private final ByteBufferPool | |
| private int | |
| private GZIPContentDecoder. | |
| private long | |
| private static final long |
| Access | Constructor and Description |
|---|---|
| public | |
| public | |
| public | |
| public |
| Modifier and Type | Method and Description |
|---|---|
| public RetainableByteBuffer | Returns: a heap buffer of the configured capacity either from the pool or freshly allocated.capacity of the ByteBuffer to acquire capacity)
|
| public RetainableByteBuffer | Returns: a buffer containing inflated data.the buffer containing compressed data. compressed)Inflates compressed data from a buffer. |
| protected void | decodeChunks(ByteBuffer
the buffer of compressed data to inflate compressed)Inflates compressed data. |
| protected boolean | Returns: false if inflating should continue, or true if the call todecodeChunks(ByteBuffer) or decode(ByteBuffer)
should return, allowing to consume the inflated chunk and apply
backpressurethe inflated chunk of data chunk)Called when a chunk of data is inflated. |
| public void | |
| public boolean | |
| private void |
| _bufferSize | back to summary |
|---|---|
| private final int _bufferSize | |
| _flags | back to summary |
|---|---|
| private byte _flags | |
| _inflated | back to summary |
|---|---|
| private RetainableByteBuffer _inflated | |
| _inflateds | back to summary |
|---|---|
| private final List<RetainableByteBuffer> _inflateds | |
| _inflater | back to summary |
|---|---|
| private Inflater _inflater | |
| _inflaterEntry | back to summary |
|---|---|
| private CompressionPool<Inflater>. | |
| _pool | back to summary |
|---|---|
| private final ByteBufferPool _pool | |
| _size | back to summary |
|---|---|
| private int _size | |
| _state | back to summary |
|---|---|
| private GZIPContentDecoder. | |
| _value | back to summary |
|---|---|
| private long _value | |
| UINT_MAX | back to summary |
|---|---|
| private static final long UINT_MAX | |
| GZIPContentDecoder | back to summary |
|---|---|
| public GZIPContentDecoder() | |
| GZIPContentDecoder | back to summary |
|---|---|
| public GZIPContentDecoder(int bufferSize) | |
| GZIPContentDecoder | back to summary |
|---|---|
| public GZIPContentDecoder(ByteBufferPool byteBufferPool, int bufferSize) | |
| GZIPContentDecoder | back to summary |
|---|---|
| public GZIPContentDecoder(InflaterPool inflaterPool, ByteBufferPool byteBufferPool, int bufferSize) | |
| acquire | back to summary |
|---|---|
public RetainableByteBuffer acquire(int capacity)
| |
| decode | back to summary |
|---|---|
| public RetainableByteBuffer decode(ByteBuffer compressed) Inflates compressed data from a buffer. The This method may fully consume the input buffer, but return only a chunk of the inflated bytes, to allow applications to consume the inflated chunk before performing further inflation, applying backpressure. In this case, this method should be invoked again with the same input buffer (even if it's already fully consumed) and that will produce another chunk of inflated bytes. Termination happens when the input buffer is fully consumed, and the returned buffer is empty. See
| |
| decodeChunks | back to summary |
|---|---|
| protected void decodeChunks(ByteBuffer compressed) Inflates compressed data. Inflation continues until the compressed block end is reached, there is no
more compressed data or a call to
| |
| decodedChunk | back to summary |
|---|---|
| protected boolean decodedChunk(RetainableByteBuffer chunk) Called when a chunk of data is inflated. The default implementation aggregates all the chunks
into a single buffer returned from Derived implementations may choose to consume inflated chunks
individually and return
| |
| destroy | back to summary |
|---|---|
| public void destroy() Implements org.
| |
| isFinished | back to summary |
|---|---|
| public boolean isFinished() | |
| reset | back to summary |
|---|---|
| private void reset() | |
| Modifier and Type | Field and Description |
|---|---|
| public static final GZIPContentDecoder. | |
| public static final GZIPContentDecoder. | |
| public static final GZIPContentDecoder. | |
| public static final GZIPContentDecoder. | |
| public static final GZIPContentDecoder. | |
| public static final GZIPContentDecoder. | |
| public static final GZIPContentDecoder. | |
| public static final GZIPContentDecoder. | |
| public static final GZIPContentDecoder. | |
| public static final GZIPContentDecoder. | |
| public static final GZIPContentDecoder. | |
| public static final GZIPContentDecoder. | |
| public static final GZIPContentDecoder. | |
| public static final GZIPContentDecoder. | |
| public static final GZIPContentDecoder. | |
| public static final GZIPContentDecoder. |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static GZIPContentDecoder. | |
| public static GZIPContentDecoder. |
| CM | back to summary |
|---|---|
| public static final GZIPContentDecoder. | |
| COMMENT | back to summary |
|---|---|
| public static final GZIPContentDecoder. | |
| CRC | back to summary |
|---|---|
| public static final GZIPContentDecoder. | |
| DATA | back to summary |
|---|---|
| public static final GZIPContentDecoder. | |
| EXTRA | back to summary |
|---|---|
| public static final GZIPContentDecoder. | |
| EXTRA_LENGTH | back to summary |
|---|---|
| public static final GZIPContentDecoder. | |
| FLAGS | back to summary |
|---|---|
| public static final GZIPContentDecoder. | |
| FLG | back to summary |
|---|---|
| public static final GZIPContentDecoder. | |
| HCRC | back to summary |
|---|---|
| public static final GZIPContentDecoder. | |
| ID | back to summary |
|---|---|
| public static final GZIPContentDecoder. | |
| INITIAL | back to summary |
|---|---|
| public static final GZIPContentDecoder. | |
| ISIZE | back to summary |
|---|---|
| public static final GZIPContentDecoder. | |
| MTIME | back to summary |
|---|---|
| public static final GZIPContentDecoder. | |
| NAME | back to summary |
|---|---|
| public static final GZIPContentDecoder. | |
| OS | back to summary |
|---|---|
| public static final GZIPContentDecoder. | |
| XFL | back to summary |
|---|---|
| public static final GZIPContentDecoder. | |
| State | back to summary |
|---|---|
| private State() | |
| valueOf | back to summary |
|---|---|
| public static GZIPContentDecoder. | |
| values | back to summary |
|---|---|
| public static GZIPContentDecoder. | |