liststorage

package
v0.3.9 Latest Latest
Warning

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

Go to latest
Published: Nov 21, 2023 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrUnknownAclId  = errors.New("acl does not exist")
	ErrAclExists     = errors.New("acl already exists")
	ErrUnknownRecord = errors.New("record doesn't exist")
)

Functions

This section is empty.

Types

type Exporter

type Exporter interface {
	ListStorage(root *consensusproto.RawRecordWithId) (ListStorage, error)
}

type ListStorage

type ListStorage interface {
	Id() string
	Root() (*consensusproto.RawRecordWithId, error)
	Head() (string, error)
	SetHead(headId string) error

	GetRawRecord(ctx context.Context, id string) (*consensusproto.RawRecordWithId, error)
	AddRawRecord(ctx context.Context, rec *consensusproto.RawRecordWithId) error
}

func NewInMemoryAclListStorage

func NewInMemoryAclListStorage(
	id string,
	records []*consensusproto.RawRecordWithId) (ListStorage, error)

Directories

Path Synopsis
Code generated by MockGen.
Code generated by MockGen.

Jump to

Keyboard shortcuts

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