Type Definition tp_consensus::import_queue::BoxBlockImport[][src]

type BoxBlockImport<B, Transaction> = Box<dyn BlockImport<B, Error = ConsensusError, Transaction = Transaction> + Send + Sync>;

Shared block import struct used by the queue.

Trait Implementations

impl<B: BlockT, Transaction> BlockImport<B> for BoxBlockImport<B, Transaction>[src]

type Error = Error

The error type.

type Transaction = Transaction

The transaction type used by the backend.

fn check_block(
    &mut self,
    block: BlockCheckParams<B>
) -> Result<ImportResult, Self::Error>
[src]

Check block preconditions.

fn import_block(
    &mut self,
    block: BlockImportParams<B, Transaction>,
    cache: HashMap<CacheKeyId, Vec<u8>>
) -> Result<ImportResult, Self::Error>
[src]

Import a block.

Cached data can be accessed through the blockchain cache.