Versions in this module Expand all Collapse all v1 v1.0.0 May 24, 2019 Changes in this version + type CachedString string + func (c CachedString) Size() int + type Item struct + Key string + Value Value + type LRUCache struct + func NewLRUCache(capacity int64) *LRUCache + func (lru *LRUCache) Capacity() int64 + func (lru *LRUCache) Clear() + func (lru *LRUCache) Delete(key string) bool + func (lru *LRUCache) Evictions() int64 + func (lru *LRUCache) Get(key string) (v Value, ok bool) + func (lru *LRUCache) Items() []Item + func (lru *LRUCache) Keys() []string + func (lru *LRUCache) Length() int64 + func (lru *LRUCache) Oldest() (oldest time.Time) + func (lru *LRUCache) Peek(key string) (v Value, ok bool) + func (lru *LRUCache) Set(key string, value Value) + func (lru *LRUCache) SetCapacity(capacity int64) + func (lru *LRUCache) SetIfAbsent(key string, value Value) + func (lru *LRUCache) Size() int64 + func (lru *LRUCache) Stats() (length, size, capacity, evictions int64, oldest time.Time) + func (lru *LRUCache) StatsJSON() string + type StringValue string + func (s StringValue) Size() int + type Value interface + Size func() int