Class FrontCodedIndexedWriter

  • All Implemented Interfaces:
    DictionaryWriter<byte[]>, Serializer

    public class FrontCodedIndexedWriter
    extends Object
    implements DictionaryWriter<byte[]>
    DictionaryWriter for a FrontCodedIndexed, written to a SegmentWriteOutMedium. Values MUST be added to this dictionary writer in sorted order, which is enforced. Front coding is a type of delta encoding for byte arrays, where values are grouped into buckets. The first value of the bucket is written entirely, and remaining values are stored as pairs of an integer which indicates how much of the first byte array of the bucket to use as a prefix, (or the preceding value of the bucket if using 'incremental' buckets) followed by the remaining value bytes after the prefix. This writer is designed for use with UTF-8 encoded strings that are written in an order compatible with String.compareTo(String).
    See Also:
    for additional details.
    • Constructor Detail

      • FrontCodedIndexedWriter

        public FrontCodedIndexedWriter​(SegmentWriteOutMedium segmentWriteOutMedium,
                                       ByteOrder byteOrder,
                                       int bucketSize,
                                       byte version)