robinhood

package
v0.0.0-...-5b112dc Latest Latest
Warning

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

Go to latest
Published: May 26, 2021 License: BSD-3-Clause Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Hash

func Hash(s string) uint32

Types

type Entry

type Entry struct {
	// contains filtered or unexported fields
}

type Hasher

type Hasher interface {
	Hash(s string) uint32
}

type RobinHood

type RobinHood struct {
	// contains filtered or unexported fields
}

func NewRobinHood

func NewRobinHood(size int, hash Hasher) *RobinHood

func (*RobinHood) DibAverage

func (m *RobinHood) DibAverage() float32

func (*RobinHood) Erase

func (m *RobinHood) Erase(k string)

func (*RobinHood) Get

func (m *RobinHood) Get(k string) interface{}

func (*RobinHood) LoadFactor

func (m *RobinHood) LoadFactor() float32

func (*RobinHood) Put

func (m *RobinHood) Put(k string, v interface{})

func (RobinHood) Size

func (m RobinHood) Size() uint32

func (*RobinHood) String

func (m *RobinHood) String() string

Jump to

Keyboard shortcuts

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