Documentation ¶
Index ¶
- func NewARCBuffer[K BufferKey](size int) func(generator func(K) any) Buffer[K]
- func NewLFUBuffer[K BufferKey](size int) func(generator func(K) any) Buffer[K]
- func NewLRUBuffer[K BufferKey](size int) func(generator func(K) any) Buffer[K]
- func NewUnlimitedBuffer[K BufferKey]() func(generator func(K) any) Buffer[K]
- type ARCBuffer
- type Buffer
- type BufferKey
- type LFUBuffer
- type LRUBuffer
- type UnlimitedBuffer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewUnlimitedBuffer ¶
Types ¶
type ARCBuffer ¶
type ARCBuffer[K BufferKey] struct { // contains filtered or unexported fields }
func (ARCBuffer[K]) GetOrInsert ¶
type LFUBuffer ¶
type LFUBuffer[K BufferKey] struct { // contains filtered or unexported fields }
func (LFUBuffer[K]) GetOrInsert ¶
type LRUBuffer ¶
type LRUBuffer[K BufferKey] struct { // contains filtered or unexported fields }
func (LRUBuffer[K]) GetOrInsert ¶
type UnlimitedBuffer ¶
type UnlimitedBuffer[K BufferKey] struct { // contains filtered or unexported fields }
func (UnlimitedBuffer[K]) GetOrInsert ¶
func (b UnlimitedBuffer[K]) GetOrInsert(key K) (any, bool)
Click to show internal directories.
Click to hide internal directories.