bloom-bitset 11.2.0

Zero-dependency probabilistic data structures: 512-bit cache-line-blocked Bloom filter, 4-bit saturating Counting Bloom filter, and HyperLogLog cardinality estimator.
Documentation
1
2
3
4
5
6
7
8
9
10
/// A 4-bit saturating Counting Bloom filter supporting insertion, membership queries, and deletion.
#[derive(Clone, Debug, Eq, PartialEq)]
pub struct CountingBloomFilter {
    /// Packed 4-bit counters (two counters per byte).
    pub(crate) nibbles: Vec<u8>,
    /// Total number of 4-bit counter slots.
    pub(crate) slot_count: usize,
    /// Number of hash probes per element (`1..=16`).
    pub(crate) hash_count: u32,
}