public class NoopCompressor<B> extends Object implements Compressor<B>
| Constructor and Description |
|---|
NoopCompressor() |
| Modifier and Type | Method and Description |
|---|---|
String |
algorithm()
The name of the algorithm used.
|
B |
compress(B uncompressed)
Compresses a payload using the "legacy" format of protocol v4- frame bodies.
|
B |
compressWithoutLength(B uncompressed)
Compresses a payload using the "modern" format of protocol v5+ segments.
|
B |
decompress(B compressed)
Decompresses a payload that was compressed with
Compressor.compress(Object). |
B |
decompressWithoutLength(B compressed,
int uncompressedLength)
Decompresses a payload that was compressed with
Compressor.compressWithoutLength(Object). |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitnonepublic String algorithm()
CompressorIt's the string that will be used in the STARTUP message. Null or empty means no
compression.
algorithm in interface Compressor<B>public B compress(B uncompressed)
CompressorThe resulting payload encodes the uncompressed length, and is therefore self-sufficient for decompression.
compress in interface Compressor<B>public B decompress(B compressed)
CompressorCompressor.compress(Object).decompress in interface Compressor<B>public B compressWithoutLength(B uncompressed)
CompressorThe resulting payload does not encode the uncompressed length. It must be stored separately, and provided to the decompression method.
compressWithoutLength in interface Compressor<B>public B decompressWithoutLength(B compressed, int uncompressedLength)
CompressorCompressor.compressWithoutLength(Object).decompressWithoutLength in interface Compressor<B>Copyright © 2017–2022. All rights reserved.