ByteBuf encoded with the Snappy framing format.
See Snappy framing format.
Note that by default, validation of the checksum header in each chunk is
DISABLED for performance improvements. If performance is less of an issue,
or if you would prefer the safety that checksum validation brings, please
use the SnappyFrameDecoder(boolean) constructor with the argument
set to true.
| Modifier and Type | Class and Description |
|---|---|
| private static enum |
| Modifier and Type | Field and Description |
|---|---|
| private boolean | |
| private static final int | |
| private static final int | |
| private static final int | |
| private int | |
| private final Snappy | |
| private static final int | |
| private boolean | |
| private final boolean |
| Access | Constructor and Description |
|---|---|
| public | |
| public | SnappyFrameDecoder(boolean
If true, the checksum field will be validated against the actual
uncompressed data, and if the checksums do not match, a suitable
validateChecksums)DecompressionException will be thrownCreates a new snappy-framed decoder with validation of checksums as specified. |
| Modifier and Type | Method and Description |
|---|---|
| private static void | |
| protected void | decode(ChannelHandlerContext
the ctx, ByteBuf ChannelHandlerContext which this ByteToMessageDecoder belongs tothe in, List<Object> ByteBuf from which to read datathe out)List to which decoded messages should be addedImplements abstract io. ByteBuf to an other.
|
| private static SnappyFrameDecoder. | mapChunkType(byte
The tag byte extracted from the stream type)Decodes the chunk type from the type tag byte. |
| corrupted | back to summary |
|---|---|
| private boolean corrupted | |
| MAX_COMPRESSED_CHUNK_SIZE | back to summary |
|---|---|
| private static final int MAX_COMPRESSED_CHUNK_SIZE | |
| MAX_DECOMPRESSED_DATA_SIZE | back to summary |
|---|---|
| private static final int MAX_DECOMPRESSED_DATA_SIZE | |
| MAX_UNCOMPRESSED_DATA_SIZE | back to summary |
|---|---|
| private static final int MAX_UNCOMPRESSED_DATA_SIZE | |
| numBytesToSkip | back to summary |
|---|---|
| private int numBytesToSkip | |
| snappy | back to summary |
|---|---|
| private final Snappy snappy | |
| SNAPPY_IDENTIFIER_LEN | back to summary |
|---|---|
| private static final int SNAPPY_IDENTIFIER_LEN | |
| started | back to summary |
|---|---|
| private boolean started | |
| validateChecksums | back to summary |
|---|---|
| private final boolean validateChecksums | |
| SnappyFrameDecoder | back to summary |
|---|---|
| public SnappyFrameDecoder() Creates a new snappy-framed decoder with validation of checksums
turned OFF. To turn checksum validation on, please use the alternate
| |
| SnappyFrameDecoder | back to summary |
|---|---|
| public SnappyFrameDecoder(boolean validateChecksums) Creates a new snappy-framed decoder with validation of checksums as specified.
| |
| checkByte | back to summary |
|---|---|
| private static void checkByte(byte actual, byte expect) | |
| decode | back to summary |
|---|---|
| protected void decode(ChannelHandlerContext ctx, ByteBuf in, List<Object> out) throws Exception Implements abstract io. Doc from io. Decode the from one
| |
| mapChunkType | back to summary |
|---|---|
| private static SnappyFrameDecoder. Decodes the chunk type from the type tag byte.
| |
| Modifier and Type | Field and Description |
|---|---|
| public static final SnappyFrameDecoder. | |
| public static final SnappyFrameDecoder. | |
| public static final SnappyFrameDecoder. | |
| public static final SnappyFrameDecoder. | |
| public static final SnappyFrameDecoder. |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static SnappyFrameDecoder. | |
| public static SnappyFrameDecoder. |
| COMPRESSED_DATA | back to summary |
|---|---|
| public static final SnappyFrameDecoder. | |
| RESERVED_SKIPPABLE | back to summary |
|---|---|
| public static final SnappyFrameDecoder. | |
| RESERVED_UNSKIPPABLE | back to summary |
|---|---|
| public static final SnappyFrameDecoder. | |
| STREAM_IDENTIFIER | back to summary |
|---|---|
| public static final SnappyFrameDecoder. | |
| UNCOMPRESSED_DATA | back to summary |
|---|---|
| public static final SnappyFrameDecoder. | |
| ChunkType | back to summary |
|---|---|
| private ChunkType() | |
| valueOf | back to summary |
|---|---|
| public static SnappyFrameDecoder. | |
| values | back to summary |
|---|---|
| public static SnappyFrameDecoder. | |