Bloom Filter
A Bloom filter for instances of E
that implements the ProbabilisticFilter interface.
This implementation is backed by Google Guava's BloomFilter
.
From Guava:
A Bloom filter offers an approximate containment test with one-sided error: if it claims that an element is contained in it, this might be in error, but if it claims that an element is not contained in it, then this is definitely true.If you are unfamiliar with Bloom filters, this nice tutorial may help you understand how they work.
The false positive probability (
FPP
) of a bloom filter is defined as the probability that contains will erroneously returntrue
for an object that has not actually been put in the BloomFilter.
Author
Brian Dupras
Guava Authors (underlying BloomFilter implementation)
Parameters
<E>
the type of instances that the BloomFilter accepts.
See also
<a target="guavadoc" href="http://google. github. io/guava/releases/snapshot/api/docs/com/google/common/hash/Bloom Filter. html">com. google. common. hash. Bloom Filter</a>
Functions
Link copied to clipboard
Adds all of the elements in the specified collection to this filter.
Combines
this
filter with another compatible filter.Link copied to clipboard
Returns
true
if this filter might contain all of the elements of the specified collection (optional operation).Not supported.
Link copied to clipboard
Creates a new BloomFilter that's a copy of this instance.
Link copied to clipboard
Creates a BloomFilter with the expected number of insertions and a default expected false positive probability of 3%.
Creates a BloomFilter with the expected number of insertions and expected false positive probability.
Link copied to clipboard
Returns the current false positive probability (
FPP
) of this filter.Link copied to clipboard
Returns
true
if the specified filter is compatible with this
filter.Link copied to clipboard
Not supported.