Documentation ¶
Index ¶
Constants ¶
View Source
const (
UnlimitedCapacity = 0 // unlimited capacity
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Implementation ¶
type Implementation byte
Implementation represents a memory caching container that implemented in another package.
const ( FIFO Implementation = iota + 1 // imports github.com/wayn3h0/go-caching/container/memory/fifo LFU // imports github.com/wayn3h0/go-caching/container/memory/lfu LRU // imports github.com/wayn3h0/go-caching/container/memory/lru MRU // imports github.com/wayn3h0/go-caching/container/memory/mru ARC // imports github.com/wayn3h0/go-caching/container/memory/arc )
func (Implementation) Available ¶
func (this Implementation) Available() bool
Available reports whether the given container is linked into the binary.
func (Implementation) New ¶
func (this Implementation) New(capacity int) caching.Container
New returns a new memory container.
func (Implementation) Register ¶
func (this Implementation) Register(function func(int) caching.Container)
Register registers the container implementation. This is intended to be called from the init function in packages that implement container functions.
Click to show internal directories.
Click to hide internal directories.