Versions in this module Expand all Collapse all v0 v0.0.1 Jun 5, 2017 Changes in this version + type Cache struct + func New(capacity int, maxNrDirty int, flushPeriod time.Duration, flusher Flusher) *Cache + func (c *Cache) Delete(key string) interface{} + func (c *Cache) Flush() + func (c *Cache) Get(key string) interface{} + func (c *Cache) Len() int + func (c *Cache) Set(key string, value interface{}) + type CacheInterface interface + Delete func(key string) interface{} + Flush func() + Get func(key string) interface{} + Len func() int + Set func(key string, value interface{}) + type Flusher interface + Add func(key string, value interface{}) + Remove func(key string) + type SimpleCache struct + func NewSimple(capacity int) *SimpleCache + func (c *SimpleCache) Delete(key string) interface{} + func (c *SimpleCache) Flush() + func (c *SimpleCache) Get(key string) interface{} + func (c *SimpleCache) Len() int + func (c *SimpleCache) Set(key string, value interface{})