Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrEndOfTime = errors.New("program time is suspiciously far in the future") ErrNoPendingBlocks = errors.New("no pending blocks") )
Functions ¶
Types ¶
type Builder ¶
type Builder interface { mempool.Mempool // StartBlockTimer starts to issue block creation requests to advance the // chain timestamp. StartBlockTimer() // ResetBlockTimer forces the block timer to recalculate when it should // advance the chain timestamp. ResetBlockTimer() // ShutdownBlockTimer stops block creation requests to advance the chain // timestamp. // // Invariant: Assumes the context lock is held when calling. ShutdownBlockTimer() // BuildBlock can be called to attempt to create a new block BuildBlock(context.Context) (snowman.Block, error) // PackAllBlockTxs returns an array of all txs that could be packed into a // valid block of infinite size. The returned txs are all verified against // the preferred state. // // Note: This function does not call the consensus engine. PackAllBlockTxs() ([]*txs.Tx, error) }
func New ¶
func New( mempool mempool.Mempool, txExecutorBackend *txexecutor.Backend, blkManager blockexecutor.Manager, ) Builder
Click to show internal directories.
Click to hide internal directories.