View Source jhn_bloom (jhn_stdlib v5.3.2)
Implements Bloom filters Based on: Scalable Bloom Filters by Paulo Sérgio Almeida, Carlos Baquero, Nuno Preguiça, David Hutchison
Summary
Functions
Adds a term to the Bloom filter
Returns the capacity of the Bloom filter
Returns a bloom filter
Returns a bloom filter Options are: fixed -> standard partitioned bloom filter, default type scalable -> scalable bloom filter size -> the maximum size for fixed and initial size for scalable filter the defaults are 4000 and 32000 respectively error_prob -> error probability, default 0.001 Options relevant to scalable filters only growth_ratio -> log 2 of growth ratio, one of 1, 2, 3 default 1 error_ratio -> error probability ratio, default 0.85
Returns true if the argument is a Bloom filter
Returns if the term is a member of the Bloom filter
Returns the type of Bloom filter
Types
-opaque filter()
Functions
Adds a term to the Bloom filter
Returns the capacity of the Bloom filter
-spec filter() -> filter().
Returns a bloom filter
Returns a bloom filter Options are: fixed -> standard partitioned bloom filter, default type scalable -> scalable bloom filter size -> the maximum size for fixed and initial size for scalable filter the defaults are 4000 and 32000 respectively error_prob -> error probability, default 0.001 Options relevant to scalable filters only growth_ratio -> log 2 of growth ratio, one of 1, 2, 3 default 1 error_ratio -> error probability ratio, default 0.85
-spec is_filter(_) -> boolean().
Returns true if the argument is a Bloom filter
Returns if the term is a member of the Bloom filter
-spec type(_) -> fixed | scalable.
Returns the type of Bloom filter