slotkeyrepo

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Feb 1, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const SlotPrefix = "slot/"

Variables

This section is empty.

Functions

This section is empty.

Types

type SlotKeyEntry

type SlotKeyEntry struct {
	Slot  uint16
	Key   string
	Value string
}

type SlotKeyRepo

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

SlotKeyRepo saves information about the slot and cid key mapping.

func NewSlotKeyRepo

func NewSlotKeyRepo(db objmetadb.ObjStoreMetaDBAPI) *SlotKeyRepo

func (*SlotKeyRepo) AllKeysChan

func (s *SlotKeyRepo) AllKeysChan(ctx context.Context, slot uint16, seekSlotKey string) (<-chan *SlotKeyEntry, error)

func (*SlotKeyRepo) Get

func (s *SlotKeyRepo) Get(slot uint16, key string) (value string, err error)

func (*SlotKeyRepo) Has

func (s *SlotKeyRepo) Has(slot uint16, key string) (bool, error)

func (*SlotKeyRepo) Remove

func (s *SlotKeyRepo) Remove(slot uint16, key string) error

func (*SlotKeyRepo) Set

func (s *SlotKeyRepo) Set(slot uint16, key string, value string) error

Jump to

Keyboard shortcuts

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