Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Cache ¶
type Cache struct { // If len > UpperBound, cache will automatically evict // down to LowerBound. If either value is 0, this behavior // is disabled. UpperBound int LowerBound int EvictionChannel chan<- Eviction // contains filtered or unexported fields }
func (*Cache) Get ¶
Get retrieves the key's value if it exists, incrementing the frequency. It returns nil if there is no value for the given key.
func (*Cache) GetFrequency ¶
GetFrequency returns the frequency count of the given key
Click to show internal directories.
Click to hide internal directories.