bloom

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Jan 9, 2024 License: BSD-3-Clause Imports: 4 Imported by: 152

Documentation

Overview

Package bloom implements Bloom filters.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FilterPolicy

type FilterPolicy int

FilterPolicy implements the FilterPolicy interface from the pebble package.

The integer value is the approximate number of bits used per key. A good value is 10, which yields a filter with ~ 1% false positive rate.

func (FilterPolicy) MayContain

func (p FilterPolicy) MayContain(ftype base.FilterType, f, key []byte) bool

MayContain implements the pebble.FilterPolicy interface.

func (FilterPolicy) Name

func (p FilterPolicy) Name() string

Name implements the pebble.FilterPolicy interface.

func (FilterPolicy) NewWriter

func (p FilterPolicy) NewWriter(ftype base.FilterType) base.FilterWriter

NewWriter implements the pebble.FilterPolicy interface.

Jump to

Keyboard shortcuts

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