package
Version:
v0.9.1
Opens a new window with list of versions in this module.
Published: Apr 30, 2019
License: ISC, MIT
Opens a new window with license information.
Imports: 4
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
NewCache return a cache with specified capacity, the cache's size can't
exceed that given capacity.
Get will return value for a given key, making the element the most recently
accessed item in the process. Will return nil if the key isn't found.
Len returns number of elements in the cache.
Put inserts a given (key,value) pair into the cache, if the key already
exists, it will replace value and update it to be most recent item in cache.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.