public class AirBlockCompressor extends Object implements BlockCompressor
Compressor.| 构造器和说明 |
|---|
AirBlockCompressor(io.airlift.compress.Compressor internalCompressor) |
| 限定符和类型 | 方法和说明 |
|---|---|
int |
compress(byte[] src,
int srcOff,
int srcLen,
byte[] dst,
int dstOff)
Compress data read from src, and write the compressed data to dst.
|
int |
compress(ByteBuffer src,
int srcOff,
int srcLen,
ByteBuffer dst,
int dstOff)
Compress source data read from (
Buffer.position() + srcOff), and write
the compressed data to dst. |
int |
getMaxCompressedSize(int srcSize)
Get the max compressed size for a given original size.
|
public AirBlockCompressor(io.airlift.compress.Compressor internalCompressor)
public int getMaxCompressedSize(int srcSize)
BlockCompressorgetMaxCompressedSize 在接口中 BlockCompressorpublic int compress(ByteBuffer src, int srcOff, int srcLen, ByteBuffer dst, int dstOff) throws BufferCompressionException
BlockCompressorBuffer.position() + srcOff), and write
the compressed data to dst.compress 在接口中 BlockCompressorsrc - Uncompressed data to read fromsrcOff - The start offset of uncompressed datasrcLen - The length of data which want to be compresseddst - The target to write compressed datadstOff - The start offset to write the compressed dataBufferCompressionException - if exception thrown when compressingpublic int compress(byte[] src,
int srcOff,
int srcLen,
byte[] dst,
int dstOff)
throws BufferCompressionException
BlockCompressorcompress 在接口中 BlockCompressorsrc - Uncompressed data to read fromsrcOff - The start offset of uncompressed datasrcLen - The length of data which want to be compresseddst - The target to write compressed datadstOff - The start offset to write the compressed dataBufferCompressionException - if exception thrown when compressingCopyright © 2014–2022 The Apache Software Foundation. All rights reserved.