cache

package
v1.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 6, 2021 License: AGPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CacheSize

func CacheSize() int

CacheSize return the size of this cache

func Clear

func Clear()

Clear the cache

func Get

func Get(key string, reset bool, ttl time.Duration) interface{}

Get a value from cache identified by the key. It also specify new TTL duration if it need to reset

func Remove

func Remove(key string)

Remove a cache entry

func Store

func Store(key string, value interface{}, ttl time.Duration)

Store a value into cache identified by the key. It also specify the TTL duration

func TimerSize

func TimerSize() int

TimerSize return the size of timer

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL