Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type LRU ¶
type LRU[K comparable, V any] struct { Size int // contains filtered or unexported fields }
LRU is a thread-safe least recently used cache with a fixed size.
func NewLRU ¶
func NewLRU[K comparable, V any](size int) *LRU[K, V]
NewLRU creates a new LRU cache with the given size
Click to show internal directories.
Click to hide internal directories.