eliminate

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Mar 4, 2023 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Core

type Core struct {
	MaxSize   int // 0 => no limit
	UsedSize  int
	OnEvicted EvictFunc
}

type Entity

type Entity struct {
	Key   Key
	Value Value
}

Entity

type EvictFunc

type EvictFunc func(key Key, value Value)

type ICore

type ICore interface {
	Add(Key, Value)
	Get(Key) (Value, bool)
	Remove(Key)
	Clear()
	Name() string
}

ICore defines allowed operations of a memo

type Key

type Key string

Entity

type Value

type Value any

Entity

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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