Template Class BinaryFuseFilter

Class Documentation

template<class T, class F = std::uint8_t, class H = DefaultHash<T>>
class BinaryFuseFilter

a static filter of the keys of type T with fingerprints of type F, 3 places per key in 3 consecutive segments

Public Functions

explicit BinaryFuseFilter(const std::vector<T> &keys, std::uint64_t seed = 1, H h = H())

the filter of the keys, which may repeat

Pre:

fewer than 2^31 keys

Post:

every key is maybe there (an audit)

bool maybe(const T &x) const

true for every key of the set, and for any other with probability about 2^-b, b the bits of F

std::size_t size(void) const

the keys of the build, the repeated ones once each

bool empty(void) const
std::size_t bits(void) const

the bits of the fingerprints

std::size_t trials(void) const

the seeds drawn by the build