Struct finality_grandpa::CommitValidationResult[][src]

pub struct CommitValidationResult<H, N> { /* fields omitted */ }

Struct returned from validate_commit function with information about the validation result.

Implementations

impl<H, N> CommitValidationResult<H, N>[src]

pub fn ghost(&self) -> Option<&(H, N)>[src]

Returns the commit GHOST i.e. the block with highest number for which the cumulative votes of descendents and itself reach finalization threshold.

pub fn num_precommits(&self) -> usize[src]

Returns the number of precommits in the commit.

pub fn num_duplicated_precommits(&self) -> usize[src]

Returns the number of duplicate precommits in the commit.

pub fn num_equivocations(&self) -> usize[src]

Returns the number of equivocated precommits in the commit.

pub fn num_invalid_voters(&self) -> usize[src]

Returns the number of invalid voters in the commit.

Trait Implementations

impl<H, N> Default for CommitValidationResult<H, N>[src]

impl<H, N> From<CommitValidationResult<H, N>> for BadCommit[src]

Auto Trait Implementations

impl<H, N> RefUnwindSafe for CommitValidationResult<H, N> where
    H: RefUnwindSafe,
    N: RefUnwindSafe

impl<H, N> Send for CommitValidationResult<H, N> where
    H: Send,
    N: Send

impl<H, N> Sync for CommitValidationResult<H, N> where
    H: Sync,
    N: Sync

impl<H, N> Unpin for CommitValidationResult<H, N> where
    H: Unpin,
    N: Unpin

impl<H, N> UnwindSafe for CommitValidationResult<H, N> where
    H: UnwindSafe,
    N: UnwindSafe

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> From<T> for T[src]

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

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.