db

package
v0.0.0-...-a65a15d Latest Latest
Warning

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

Go to latest
Published: Apr 21, 2023 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DB

type DB interface {
	Put(k string, v []byte) error
	Get(k string) ([]byte, error)

	LogEvent(e *event.Message, first bool) error
	LogTransferableReceipt(vrc *event.Receipt) error
	LogNonTransferableReceipt(rct *event.Receipt) error

	EscrowPendingEvent(e *event.Message) error
	RemovePendingEscrow(prefix string, sn int, dig string) error

	EscrowOutOfOrderEvent(e *event.Message) error
	EscrowLikelyDuplicitiousEvent(e *event.Message) error

	LogSize(pre string) int
	StreamEstablisment(pre string, handler func(*event.Message) error) error
	StreamAsFirstSeen(pre string, handler func(*event.Message) error) error
	StreamBySequenceNo(pre string, handler func(*event.Message) error) error
	StreamPending(pre string, handler func(*event.Message) error) error
	StreamTransferableReceipts(pre string, sn int, handler func(quadlet []byte) error) error

	Seen(pre string) bool
	Inception(pre string) (*event.Message, error)
	CurrentEvent(pre string) (*event.Message, error)
	CurrentEstablishmentEvent(pre string) (*event.Message, error)
	EventAt(prefix string, sequence int) (*event.Message, error)

	LastAcceptedDigest(pre string, seq int) ([]byte, error)

	Close() error
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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