cache

package
v0.0.0-...-470388c Latest Latest
Warning

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

Go to latest
Published: Sep 13, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrKeyNotFound = errors.New("key not found")
)

Functions

This section is empty.

Types

type InMemory

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

func NewInMemory

func NewInMemory() *InMemory

func (*InMemory) Clear

func (c *InMemory) Clear() error

func (*InMemory) Delete

func (c *InMemory) Delete(key string) error

func (*InMemory) Get

func (c *InMemory) Get(key string) (interface{}, error)

func (*InMemory) Keys

func (c *InMemory) Keys() []string

func (*InMemory) Set

func (c *InMemory) Set(key string, value interface{}, ttl time.Duration) error

Jump to

Keyboard shortcuts

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