readthrough2

package module
v0.0.0-...-bf55930 Latest Latest
Warning

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

Go to latest
Published: Jul 29, 2022 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ReadThroughCache

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

func NewReadThroughCache

func NewReadThroughCache(servers ...string) *ReadThroughCache

func (*ReadThroughCache) Purge

func (c *ReadThroughCache) Purge(keyOrTag string) error

Purge deletes the item with the provided key. The error ErrCacheMiss is returned if the item didn't already exist in the cache.

func (*ReadThroughCache) ReadThrough

func (c *ReadThroughCache) ReadThrough(key string, tags []string, valuePtr interface{}, readFromSource func() (valuePtr interface{}, err error)) error

Jump to

Keyboard shortcuts

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