@InterfaceAudience.Private public class PrefixTreeCodec extends Object implements DataBlockEncoder
PrefixTreeEncoder, and decoding is delegated to instances of
CellSearcher. Encoder and decoder instances are
created and recycled by static PtEncoderFactory and PtDecoderFactory.DataBlockEncoder.EncodedSeeker| Constructor and Description |
|---|
PrefixTreeCodec()
no-arg constructor for reflection
|
public ByteBuffer decodeKeyValues(DataInputStream source, HFileBlockDecodingContext decodingCtx) throws IOException
decodeKeyValues in interface DataBlockEncoderIOExceptionpublic ByteBuffer decodeKeyValues(DataInputStream source, int allocateHeaderLength, int skipLastBytes, HFileBlockDecodingContext decodingCtx) throws IOException
IOExceptionpublic ByteBuffer getFirstKeyInBlock(ByteBuffer block)
getFirstKeyInBlock in interface DataBlockEncoderpublic HFileBlockEncodingContext newDataBlockEncodingContext(DataBlockEncoding encoding, byte[] header, HFileContext meta)
newDataBlockEncodingContext in interface DataBlockEncoderpublic HFileBlockDecodingContext newDataBlockDecodingContext(HFileContext meta)
newDataBlockDecodingContext in interface DataBlockEncoderpublic DataBlockEncoder.EncodedSeeker createSeeker(KeyValue.KVComparator comparator, HFileBlockDecodingContext decodingCtx)
createSeeker in interface DataBlockEncoderpublic int encode(Cell cell, HFileBlockEncodingContext encodingCtx, DataOutputStream out) throws IOException
encode in interface DataBlockEncoderIOExceptionpublic void startBlockEncoding(HFileBlockEncodingContext blkEncodingCtx, DataOutputStream out) throws IOException
startBlockEncoding in interface DataBlockEncoderIOExceptionpublic void endBlockEncoding(HFileBlockEncodingContext encodingCtx, DataOutputStream out, byte[] uncompressedBytesWithHeader) throws IOException
endBlockEncoding in interface DataBlockEncoderIOExceptionCopyright © 2007-2016 The Apache Software Foundation. All Rights Reserved.