ttlmap

package
v0.0.19 Latest Latest
Warning

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

Go to latest
Published: Sep 20, 2023 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type TTLMap

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

func NewTTLMap

func NewTTLMap() *TTLMap

func (*TTLMap) Delete

func (m *TTLMap) Delete(k string)

func (*TTLMap) Get

func (m *TTLMap) Get(k string) (v any, ok bool)

func (*TTLMap) Set

func (m *TTLMap) Set(k string, v any, ttl int64)

ttl が 0 以下の場合は、無期限保持とする

Jump to

Keyboard shortcuts

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