1 #include <bf/bloom_filter/bitwise.h>
6 : k_(k), cells_(cells), seed_(seed)
15 while (l < levels_.size())
18 levels_[l++].remove(o);
27 levels_.back().add(o);
33 for (
size_t l = 0; l < levels_.size(); ++l)
34 result += levels_[l].
lookup(o) << l;
46 auto l = levels_.size();
49 static size_t const min_size = 128;
50 auto cells = l == 0 ? min_size : cells_ / (2 * l);
55 std::minstd_rand0 prng(seed);
56 for (
size_t i = 0; i < l; ++i)
59 levels_.emplace_back(make_hasher(k_, seed), cells);