inmemory

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: May 11, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrUserNotFound = errors.New("user not found")

Functions

This section is empty.

Types

type Storage

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

func NewStorage

func NewStorage(logger *zap.Logger) *Storage

func (*Storage) Delete

func (s *Storage) Delete(key string) error

func (*Storage) Get

func (s *Storage) Get(key string) (*user.User, error)

func (*Storage) GetWhere

func (s *Storage) GetWhere(predicate func(*user.User) bool) (*user.User, error)

func (*Storage) Set

func (s *Storage) Set(key string, value *user.User) error

Jump to

Keyboard shortcuts

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