cache

package
v1.0.1-0...-2bcd4e9 Latest Latest
Warning

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

Go to latest
Published: Oct 11, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Records

type Records struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

func NewCacheRecords

func NewCacheRecords(limit int) *Records

func (*Records) Del

func (t *Records) Del(key string) bool

func (*Records) DelExpiredItems

func (t *Records) DelExpiredItems(timestamp int64) int

func (*Records) Get

func (t *Records) Get(key string) (config.SockTable, bool)

func (*Records) Items

func (t *Records) Items() []config.SockTable

func (*Records) Set

func (t *Records) Set(key string, val config.SockTable, timestamp int64) error

type Statistics

type Statistics struct {
	Total    int
	Disabled int
}

Jump to

Keyboard shortcuts

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