expiredMap

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Apr 2, 2023 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrMapClose = errors.New("ExpiredMap is close")
)

Functions

This section is empty.

Types

type ExpiredMap

type ExpiredMap struct {
	// contains filtered or unexported fields
}

func New

func New() *ExpiredMap

func (*ExpiredMap) CheckClose

func (e *ExpiredMap) CheckClose() bool

func (*ExpiredMap) Close

func (e *ExpiredMap) Close() error

func (*ExpiredMap) Delete

func (e *ExpiredMap) Delete(key interface{}) error

func (*ExpiredMap) Get

func (e *ExpiredMap) Get(key interface{}) (interface{}, bool, error)

func (*ExpiredMap) Range

func (e *ExpiredMap) Range(f func(key, value interface{}, ttl *time.Duration)) error

func (*ExpiredMap) Set

func (e *ExpiredMap) Set(key, value interface{}, ttl ...time.Duration) error

func (*ExpiredMap) SetAutoClearInterval

func (e *ExpiredMap) SetAutoClearInterval(i time.Duration) error

func (*ExpiredMap) TTL

func (e *ExpiredMap) TTL(key interface{}) (time.Duration, error)

Jump to

Keyboard shortcuts

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