stores

package
v0.7.1-beta.2 Latest Latest
Warning

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

Go to latest
Published: Jun 28, 2023 License: GPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CategorySetKeyName

func CategorySetKeyName(category string) string

CategorySetKeyName returns the key name for a category set. (i.e. UnclaimedWallets, ControlledWallets, PendingClaims)

func KeyshareMapKeyName

func KeyshareMapKeyName(did string) string

KeyshareMapKeyName returns the key name for a keyshare map. Parameter should be a did.

func PrimaryListKeyName

func PrimaryListKeyName(address string) string

PrimaryListKeyName returns the key name for a primary account list. Parameter should be an idx... address.

Types

type Store

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

func NewIcefireStore

func NewIcefireStore(opts ...StoreOption) (*Store, error)

func (*Store) AddListItem

func (s *Store) AddListItem(key string, value string) error

func (*Store) AddMapItem

func (s *Store) AddMapItem(key string, field string, value string) error

func (*Store) AddSetItem

func (s *Store) AddSetItem(key string, member string) error

func (*Store) DelListItem

func (s *Store) DelListItem(key string, value string) (int64, error)

func (*Store) DelMapItem

func (s *Store) DelMapItem(key string, field string) (int64, error)

func (*Store) DelSetItem

func (s *Store) DelSetItem(key string, member string) (int64, error)

func (*Store) ExistsInList

func (s *Store) ExistsInList(key string, value string) (bool, error)

func (*Store) ExistsInMap

func (s *Store) ExistsInMap(key string, field string) (bool, error)

func (*Store) ExistsInSet

func (s *Store) ExistsInSet(key string, member string) (bool, error)

func (*Store) GetList

func (s *Store) GetList(key string) ([]string, error)

func (*Store) GetMap

func (s *Store) GetMap(key string) (map[string]string, error)

func (*Store) GetSet

func (s *Store) GetSet(key string) ([]string, error)

type StoreOption

type StoreOption func(*Store)

func WithAddr

func WithAddr(addr string) StoreOption

Jump to

Keyboard shortcuts

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