Encodes a strictly increasing sequence of unsigned integers as a bit vector.

Synopsis

Declared in <folly/compression/elias_fano/BitVectorCoding.h>

template<
    class Value,
    class SkipValue,
    size_t kSkipQuantum = 0,
    size_t kForwardQuantum = 0>
struct BitVectorEncoder;

Types

Name

Description

Layout

Describes the byte layout of an encoded list and builds its sub‐ranges.

Type Aliases

Name

Description

CompressedList

Read‐only view type over an encoded list.

MutableCompressedList

Mutable view type over an encoded list.

SkipValueType

The type used to store skip and forward pointers.

ValueType

The element value type.

Member Functions

Name

Description

BitVectorEncoder [constructor]

Constructors

add

Appends the next value to the list. Values must be strictly increasing.

finish

Finalizes encoding and returns the completed compressed list.

Static Member Functions

Name

Description

encode

Encodes the strictly increasing range [begin, end) into a new list.]

Static Data Members

Name

Description

forwardQuantum

Distance (in elements) between forward pointers; 0 disables them.

skipQuantum

Distance (in values) between skip pointers; 0 disables them.

Created with MrDocs