execution

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Feb 21, 2019 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BatchCommitter

type BatchCommitter interface {
	BatchExecutor

	// Commit execution results to underlying State and provide opportunity
	// to mutate state before it is saved
	Commit() (err error)

	Fees() uint64
}

Executes transactions

func NewBatchCommitter

func NewBatchCommitter(bc *blockchain.Blockchain, eventBus events.EventBus) BatchCommitter

type BatchExecutor

type BatchExecutor interface {
	// Provides access to write lock for a BatchExecutor so reads can be prevented for the duration of a commit
	sync.Locker

	// Execute transaction against block cache (i.e. block buffer)
	Execute(txEnv *txs.Envelope, txRec *txs.Receipt) error

	// Reset executor to underlying State
	Reset() error
}

func NewBatchChecker

func NewBatchChecker(bc *blockchain.Blockchain) BatchExecutor

Wraps a cache of what is variously known as the 'check cache' and 'mempool'

type Executor

type Executor interface {
	Execute(txEnv *txs.Envelope, txRec *txs.Receipt) error
}

type Transactor

type Transactor struct {
	// contains filtered or unexported fields
}

Transactor is the controller/middleware for the v0 RPC

func NewTransactor

func NewTransactor(broadcastTxFunc func(tx tmTypes.Tx, cb func(*abciTypes.Response)) error,
	eventBus events.EventBus) *Transactor

func (*Transactor) BroadcastTxAsync

func (trans *Transactor) BroadcastTxAsync(txEnv *txs.Envelope) (*txs.Receipt, error)

func (*Transactor) BroadcastTxSync added in v0.5.0

func (trans *Transactor) BroadcastTxSync(txEnv *txs.Envelope) (*txs.Receipt, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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