Expand description

Consensus engine specification and basic implementations.

Re-exports

pub use self::signer::EngineSigner;

Modules

A module with types for declaring block rewards and a client interface for interacting with a block reward contract.

Epoch verifiers and transitions.

A signer used by Engines which need to sign messages.

Structs

Engine using AuthorityRound proof-of-authority BFT consensus.

Engine using BasicAuthority, trivial proof-of-authority consensus.

Clique Engine implementation

A full epoch transition.

An engine which does not provide any consensus mechanism, just seals blocks internally. Only seals blocks which have transactions.

InstantSeal params.

Special “no-op” verifier for stateless, epoch-less engines.

An engine which does not provide any consensus mechanism and does not seal blocks.

Enums

Generated epoch verifier.

Voting errors.

Results of a query of whether an epoch change occurred at the given block.

Fork choice.

Proof generated on epoch change.

Seal type.

The type of sealing the engine is currently able to perform.

Kind of SystemOrCodeCall, this is either an on-chain address, or code.

Constants

Default EIP-210 contract code. As defined in https://github.com/ethereum/EIPs/pull/210

The number of generations back that uncles can be.

Traits

A consensus mechanism for the chain. Generally either proof-of-work or proof-of-stake-based. Provides hooks into each of the major parts of block import.

Verifier for all blocks within an epoch with self-contained state.

Common type alias for an engine coupled with an Ethereum-like state machine.

Proof dependent on state.

Functions

Default SystemOrCodeCall implementation.

t_nb 9.3 Check whether a given block is the best block based on the default total difficulty rule.

Type Definitions

Type alias for a function we can get headers by hash through.

Type alias for a function we can query pending transitions by block hash through.

A system-calling closure. Enacts calls on a block’s state from the system address.

A system-calling closure. Enacts calls on a block’s state with code either from an on-chain contract, or hard-coded EVM or WASM (if enabled on-chain) codes.