bloom

package
v0.2.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 2, 2025 License: BSD-3-Clause Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Filter

type Filter struct {
	Hasher Hasher
	// contains filtered or unexported fields
}

func NewFilter

func NewFilter(n int, p float64, hf Hasher) *Filter

func (*Filter) Has

func (f *Filter) Has(v string) bool

func (*Filter) ReadFrom

func (f *Filter) ReadFrom(r io.Reader) (n int64, err error)

func (*Filter) Set

func (f *Filter) Set(v string)

func (Filter) WriteTo

func (f Filter) WriteTo(w io.Writer) (n int64, err error)

type HashFunc

type HashFunc func(b []byte) uint64

func (HashFunc) Hash

func (hf HashFunc) Hash(b []byte) uint64

type Hasher

type Hasher interface {
	Hash(b []byte) uint64
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL