transactor

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Aug 4, 2023 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ValidateDoidName added in v0.1.0

func ValidateDoidName(s string, valid int) bool

func ValidateTx added in v0.0.3

func ValidateTx(tree *iavl.ImmutableTree, t tx.TypedTx) error

Types

type ExecutionResult

type ExecutionResult struct {
	StateRoot   types.Hash     `json:"stateRoot"`
	TxRoot      types.Hash     `json:"txRoot"`
	Txs         types.Txs      `json:"txs"`
	ReceiptRoot types.Hash     `json:"receiptsRoot"`
	Receipts    types.Receipts `json:"receipts"`
	Rejected    []*rejectedTx  `json:"rejected,omitempty"`
	Pending     []int          `json:"pending,omitempty"`
}

func ApplyTxs

func ApplyTxs(tree *iavl.MutableTree, txs types.Txs) (*ExecutionResult, error)

type Register added in v0.0.3

type Register struct{}

func (*Register) Apply added in v0.0.3

func (r *Register) Apply(tree *iavl.MutableTree, t tx.TypedTx) (resultCode, error)

func (*Register) Validate added in v0.0.3

func (r *Register) Validate(state *iavl.ImmutableTree, t tx.TypedTx) error

type Reserve added in v0.1.0

type Reserve struct{}

func (*Reserve) Apply added in v0.1.0

func (r *Reserve) Apply(tree *iavl.MutableTree, t tx.TypedTx) (resultCode, error)

func (*Reserve) Validate added in v0.1.0

func (r *Reserve) Validate(state *iavl.ImmutableTree, t tx.TypedTx) error

type Transactor added in v0.0.3

type Transactor interface {
	Validate(tree *iavl.ImmutableTree, t tx.TypedTx) error
	Apply(tree *iavl.MutableTree, t tx.TypedTx) (resultCode, error)
}

type Update added in v0.1.0

type Update struct{}

func (*Update) Apply added in v0.1.0

func (u *Update) Apply(tree *iavl.MutableTree, t tx.TypedTx) (resultCode, error)

func (*Update) Validate added in v0.1.0

func (u *Update) Validate(state *iavl.ImmutableTree, t tx.TypedTx) error

Jump to

Keyboard shortcuts

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