cache

package
v0.0.0-...-9ac2298 Latest Latest
Warning

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

Go to latest
Published: Mar 4, 2024 License: BSD-3-Clause Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Local

type Local struct {
	Set  map[string]string
	Lock sync.RWMutex
}

func NewLocal

func NewLocal() *Local

func (*Local) AllLocal

func (c *Local) AllLocal() map[string]string

func (*Local) DelLocal

func (c *Local) DelLocal(key string)

func (*Local) FlushLocal

func (c *Local) FlushLocal()

func (*Local) GetLocal

func (c *Local) GetLocal(key string) (string, error)

func (*Local) SetLocal

func (c *Local) SetLocal(key, value string)

type Tmp

type Tmp struct {
	Expires time.Duration
	Set     *cache.Cache
}

func NewTmp

func NewTmp(expires ...time.Duration) *Tmp

func (*Tmp) AllTmp

func (c *Tmp) AllTmp() map[string]string

func (*Tmp) DelTmp

func (c *Tmp) DelTmp(cacheKey string)

func (*Tmp) FlushTmp

func (c *Tmp) FlushTmp()

func (*Tmp) GetTmp

func (c *Tmp) GetTmp(cacheKey string) interface{}

func (*Tmp) SetTmp

func (c *Tmp) SetTmp(cacheKey string, value interface{}, expireTime time.Duration)

Jump to

Keyboard shortcuts

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