[][src]Struct sc_consensus_pow::PowBlockImport

pub struct PowBlockImport<B: BlockT, I, C, S, Algorithm> { /* fields omitted */ }

A block importer for PoW.

Methods

impl<B, I, C, S, Algorithm> PowBlockImport<B, I, C, S, Algorithm> where
    B: BlockT,
    I: BlockImport<B, Transaction = TransactionFor<C, B>> + Send + Sync,
    I::Error: Into<ConsensusError>,
    C: ProvideRuntimeApi<B> + Send + Sync + HeaderBackend<B> + AuxStore + ProvideCache<B> + BlockOf,
    C::Api: BlockBuilderApi<B, Error = Error>,
    Algorithm: PowAlgorithm<B>, 
[src]

pub fn new(
    inner: I,
    client: Arc<C>,
    algorithm: Algorithm,
    check_inherents_after: <<B as BlockT>::Header as HeaderT>::Number,
    select_chain: Option<S>,
    inherent_data_providers: InherentDataProviders
) -> Self
[src]

Create a new block import suitable to be used in PoW

Trait Implementations

impl<B, I, C, S, Algorithm> BlockImport<B> for PowBlockImport<B, I, C, S, Algorithm> where
    B: BlockT,
    I: BlockImport<B, Transaction = TransactionFor<C, B>> + Send + Sync,
    I::Error: Into<ConsensusError>,
    S: SelectChain<B>,
    C: ProvideRuntimeApi<B> + Send + Sync + HeaderBackend<B> + AuxStore + ProvideCache<B> + BlockOf,
    C::Api: BlockBuilderApi<B, Error = Error>,
    Algorithm: PowAlgorithm<B>,
    Algorithm::Difficulty: 'static, 
[src]

type Error = ConsensusError

The error type.

type Transaction = TransactionFor<C, B>

The transaction type used by the backend.

impl<B: BlockT, I: Clone, C, S: Clone, Algorithm: Clone> Clone for PowBlockImport<B, I, C, S, Algorithm>[src]

Auto Trait Implementations

impl<B, I, C, S, Algorithm> !RefUnwindSafe for PowBlockImport<B, I, C, S, Algorithm>

impl<B, I, C, S, Algorithm> Send for PowBlockImport<B, I, C, S, Algorithm> where
    Algorithm: Send,
    C: Send + Sync,
    I: Send,
    S: Send,
    <<B as Block>::Header as Header>::Number: Send

impl<B, I, C, S, Algorithm> Sync for PowBlockImport<B, I, C, S, Algorithm> where
    Algorithm: Sync,
    C: Send + Sync,
    I: Sync,
    S: Sync,
    <<B as Block>::Header as Header>::Number: Sync

impl<B, I, C, S, Algorithm> Unpin for PowBlockImport<B, I, C, S, Algorithm> where
    Algorithm: Unpin,
    I: Unpin,
    S: Unpin,
    <<B as Block>::Header as Header>::Number: Unpin

impl<B, I, C, S, Algorithm> !UnwindSafe for PowBlockImport<B, I, C, S, Algorithm>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> CheckedConversion for T[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, Outer> IsWrappedBy<Outer> for T where
    Outer: AsRef<T> + AsMut<T> + From<T>,
    T: From<Outer>, 
[src]

fn from_ref(outer: &Outer) -> &T[src]

Get a reference to the inner from the outer.

fn from_mut(outer: &mut Outer) -> &mut T[src]

Get a mutable reference to the inner from the outer.

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> SaturatedConversion for T

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<S, T> UncheckedInto<T> for S where
    T: UncheckedFrom<S>, 
[src]

impl<T, S> UniqueSaturatedInto<T> for S where
    S: TryInto<T>,
    T: Bounded

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,