[][src]Struct sc_consensus_pow::PowBlockImport

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

A block importer for PoW.

Implementations

impl<B, I, C, S, Algorithm, CAW> PowBlockImport<B, I, C, S, Algorithm, CAW> 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>,
    CAW: CanAuthorWith<B>, 
[src]

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

Create a new block import suitable to be used in PoW

Trait Implementations

impl<B, I, C, S, Algorithm, CAW> BlockImport<B> for PowBlockImport<B, I, C, S, Algorithm, CAW> 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,
    CAW: CanAuthorWith<B>, 
[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, CAW: Clone> Clone for PowBlockImport<B, I, C, S, Algorithm, CAW>[src]

Auto Trait Implementations

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

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

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

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

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

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> DynClone for T where
    T: Clone
[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[src]

type Output = T

Should always be Self

impl<T> SaturatedConversion for T[src]

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
[src]

impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 
[src]