Versions in this module Expand all Collapse all v0 v0.0.2 Jul 28, 2025 v0.0.1 Apr 28, 2025 Changes in this version + type ConcurrentCounterCache interface + Add func(key interface{}, value *int64) + AddIfAbsent func(key interface{}, value *int64) (priorValue *int64) + Contains func(key interface{}) (ok bool) + Get func(key interface{}) (value *int64, isFound bool) + Keys func() []interface{} + Len func() int + Purge func() + Remove func(key interface{}) (isFound bool) + func NewLRUCacheMap(size int) ConcurrentCounterCache + type EvictCallback func(key interface{}, value interface{}) + type LRU struct + func NewLRU(size int, onEvict EvictCallback) (*LRU, error) + func (c *LRU) Add(key, value interface{}) + func (c *LRU) AddIfAbsent(key interface{}, value interface{}) (priorValue interface{}) + func (c *LRU) Contains(key interface{}) (ok bool) + func (c *LRU) Get(key interface{}) (value interface{}, isFound bool) + func (c *LRU) GetOldest() (key interface{}, value interface{}, ok bool) + func (c *LRU) Keys() []interface{} + func (c *LRU) Len() int + func (c *LRU) Peek(key interface{}) (value interface{}, isFound bool) + func (c *LRU) Purge() + func (c *LRU) Remove(key interface{}) (isFound bool) + func (c *LRU) RemoveOldest() (key interface{}, value interface{}, ok bool) + func (c *LRU) Resize(size int) (evicted int) + type LruCacheMap struct + func (c *LruCacheMap) Add(key interface{}, value *int64) + func (c *LruCacheMap) AddIfAbsent(key interface{}, value *int64) (priorValue *int64) + func (c *LruCacheMap) Contains(key interface{}) (ok bool) + func (c *LruCacheMap) Get(key interface{}) (value *int64, isFound bool) + func (c *LruCacheMap) Keys() []interface{} + func (c *LruCacheMap) Len() int + func (c *LruCacheMap) Purge() + func (c *LruCacheMap) Remove(key interface{}) (isFound bool)