store

package
v0.0.0-...-8ab0ffd Latest Latest
Warning

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

Go to latest
Published: Apr 17, 2025 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MemoryStore

type MemoryStore struct {
	Store map[string][]byte
	// contains filtered or unexported fields
}

func NewMemoryStore

func NewMemoryStore() *MemoryStore

func (*MemoryStore) Delete

func (m *MemoryStore) Delete(key string)

func (*MemoryStore) ForEach

func (m *MemoryStore) ForEach(callback func(key string, value []byte))

func (*MemoryStore) Insert

func (m *MemoryStore) Insert(key string, value []byte)

func (*MemoryStore) Retrieve

func (m *MemoryStore) Retrieve(key string) ([]byte, error)

type Store

type Store interface {
	Insert(string, []byte) error
	Retrieve(string) ([]byte, error)
	Delete(string) error
}

Jump to

Keyboard shortcuts

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