Struct vapcore_clique::Clique[][src]

pub struct Clique { /* fields omitted */ }

Clique Engine implementation

Implementations

impl Clique[src]

pub fn new(params: CliqueParams, mashina: Machine) -> Result<Arc<Self>, Error>[src]

Initialize Clique engine from empty state.

Trait Implementations

impl Engine for Clique[src]

fn sealing_state(&self) -> SealingState[src]

Clique doesn’t require external work to seal, so we always return true here.

fn generate_seal(&self, block: &ExecutedBlock, parent: &Header) -> Seal[src]

Returns if we are ready to seal, the real sealing (signing extra_data) is actually done in on_seal_block().

fn verify_block_family(
    &self,
    header: &Header,
    parent: &Header
) -> Result<(), Error>
[src]

Verify block family by looking up parent state (backfill if needed), then try to apply current header. see https://github.com/vaporyco/go-vapory/blob/master/consensus/clique/clique.go#L338

fn open_block_header_timestamp(&self, parent_timestamp: u64) -> u64[src]

Clique timestamp is set to parent + period , or current time which ever is higher.

Auto Trait Implementations

impl !RefUnwindSafe for Clique

impl Send for Clique

impl Sync for Clique

impl Unpin for Clique

impl !UnwindSafe for Clique

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> Pointable for T

type Init = T

The type for initializers.

impl<T> Same<T> for T

type Output = T

Should always be Self

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<V, T> VZip<V> for T where
    V: MultiLane<T>,