Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type SerialTransaction ¶
type SerialTransaction struct { state.NestedTransaction derived.DerivedTransactionCommitter }
TODO(patrick): implement proper transaction.
type SnapshotTree ¶
type SnapshotTree struct {
// contains filtered or unexported fields
}
SnapshotTree is a simple LSM tree representation of the key/value storage at a given point in time.
func NewSnapshotTree ¶
func NewSnapshotTree(base state.StorageSnapshot) SnapshotTree
NewSnapshotTree returns a tree with keys/values initialized to the base storage snapshot.
func (SnapshotTree) Append ¶
func (tree SnapshotTree) Append( update *state.ExecutionSnapshot, ) SnapshotTree
Append returns a new tree with updates from the execution snapshot "applied" to the original original tree.
func (SnapshotTree) Get ¶
func (tree SnapshotTree) Get(id flow.RegisterID) (flow.RegisterValue, error)
Get returns the register id's value.
type Transaction ¶
type Transaction interface { state.NestedTransaction derived.DerivedTransaction }
type TransactionComitter ¶
type TransactionComitter interface { Transaction // Validate returns nil if the transaction does not conflict with // previously committed transactions. It returns an error otherwise. Validate() error // Commit commits the transaction. If the transaction conflict with // previously committed transactions, an error is returned and the // transaction is not committed. Commit() error }
Click to show internal directories.
Click to hide internal directories.