Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Filter ¶
type Filter struct {
// contains filtered or unexported fields
}
Filter represents a bloom filter.
func NewFilter ¶
NewFilter returns a new instance of Filter using m bits and k hash functions. If m is not a power of two then it is rounded to the next highest power of 2.
func NewFilterBuffer ¶
NewFilterBuffer returns a new instance of a filter using a backing buffer. The buffer length MUST be a power of 2.
func (*Filter) Contains ¶
Contains returns true if the filter possibly contains v. Returns false if the filter definitely does not contain v.
Click to show internal directories.
Click to hide internal directories.