public class AircompressorCodec extends Object implements CompressionCodec
CompressionCodec.Modifier
Modifier and Type | Method and Description |
---|---|
boolean |
compress(ByteBuffer in,
ByteBuffer out,
ByteBuffer overflow)
Compress the in buffer to the out buffer.
|
void |
decompress(ByteBuffer in,
ByteBuffer out)
Decompress the in buffer to the out buffer.
|
protected static byte[] |
getBuffer(int size) |
CompressionCodec |
modify(EnumSet<CompressionCodec.Modifier> modifiers)
Produce a modified compression codec if the underlying algorithm allows
modification.
|
protected static byte[] getBuffer(int size)
public boolean compress(ByteBuffer in, ByteBuffer out, ByteBuffer overflow) throws IOException
CompressionCodec
compress
in interface CompressionCodec
in
- the bytes to compressout
- the uncompressed bytesoverflow
- put any additional bytes hereIOException
public void decompress(ByteBuffer in, ByteBuffer out) throws IOException
CompressionCodec
decompress
in interface CompressionCodec
in
- the bytes to decompressout
- the decompressed bytesIOException
public CompressionCodec modify(EnumSet<CompressionCodec.Modifier> modifiers)
CompressionCodec
modify
in interface CompressionCodec
modifiers
- compression modifiers (nullable)Copyright © 2013–2016 The Apache Software Foundation. All rights reserved.