Versions in this module Expand all Collapse all v0 v0.1.0 Jan 23, 2022 Changes in this version + type Cache interface + Add func(key, value interface{}) + Cap func() int + Clear func() int + Contains func(key interface{}) (ok bool) + Get func(key interface{}) (value interface{}, ok bool) + Keys func() []interface{} + Len func() int + Peek func(key interface{}) (value interface{}, ok bool) + ReCap func(int) error + Remove func(key interface{}) (ok bool) + Set func(key, value interface{}) (ok bool) + Values func() []interface{} + type LruCache struct + func NewLruCache(cap int) (*LruCache, error) + func (c *LruCache) Add(key, value interface{}) + func (c *LruCache) Cap() int + func (c *LruCache) Clear() int + func (c *LruCache) Contains(key interface{}) (ok bool) + func (c *LruCache) Get(key interface{}) (value interface{}, ok bool) + func (c *LruCache) Keys() []interface{} + func (c *LruCache) Len() int + func (c *LruCache) Peek(key interface{}) (value interface{}, ok bool) + func (c *LruCache) ReCap(newCap int) (err error) + func (c *LruCache) Remove(key interface{}) (ok bool) + func (c *LruCache) Set(key, value interface{}) (ok bool) + func (c *LruCache) Values() []interface{}