[][src]Struct hycon_rust::common::meta::Meta

pub struct Meta<HeaderType> where
    HeaderType: BlockHeader + Clone + Encode + Proto
{ pub height: u32, pub header: HeaderType, pub t_ema: f64, pub p_ema: f64, pub next_difficulty: f64, pub total_work: f64, pub file_number: Option<u32>, pub offset: Option<u64>, pub length: Option<u32>, pub status: BlockStatus, }

Fields

height: u32header: HeaderTypet_ema: f64p_ema: f64next_difficulty: f64total_work: f64file_number: Option<u32>offset: Option<u64>length: Option<u32>status: BlockStatus

Methods

impl<HeaderType> Meta<HeaderType> where
    HeaderType: BlockHeader + Clone + Encode + Proto
[src]

pub fn new(
    height: u32,
    header: HeaderType,
    t_ema: f64,
    p_ema: f64,
    next_difficulty: f64,
    total_work: f64,
    file_number: Option<u32>,
    offset: Option<u64>,
    length: Option<u32>,
    status: BlockStatus
) -> Self
[src]

Trait Implementations

impl<HeaderType> ForkChoice<Meta<HeaderType>> for Consensus where
    HeaderType: BlockHeader + Proto + Encode + Clone
[src]

impl<HeaderType> BlockForkChoice for Meta<HeaderType> where
    HeaderType: BlockHeader + Clone + Proto + Encode
[src]

impl<HeaderType> Encode for Meta<HeaderType> where
    HeaderType: BlockHeader + Clone + Proto + Encode
[src]

impl<HeaderType> Decode for Meta<HeaderType> where
    HeaderType: Proto<ProtoType = BlockHeader> + BlockHeader + Clone + Encode
[src]

impl<HeaderType> Proto for Meta<HeaderType> where
    HeaderType: BlockHeader + Clone + Proto + Encode
[src]

type ProtoType = ProtoBlockDB

impl<HeaderType: Clone> Clone for Meta<HeaderType> where
    HeaderType: BlockHeader + Clone + Encode + Proto
[src]

fn clone_from(&mut self, source: &Self)
1.0.0
[src]

Performs copy-assignment from source. Read more

impl<HeaderType: Debug> Debug for Meta<HeaderType> where
    HeaderType: BlockHeader + Clone + Encode + Proto
[src]

Auto Trait Implementations

impl<HeaderType> Send for Meta<HeaderType> where
    HeaderType: Send

impl<HeaderType> Sync for Meta<HeaderType> where
    HeaderType: Sync

Blanket Implementations

impl<T> From for T[src]

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

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

type Owned = T

The resulting type after obtaining ownership.

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

type Error = Infallible

The type returned in the event of a conversion error.

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

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

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

impl<T, U> TryInto 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<T> SendSyncUnwindSafe for T where
    T: Send + Sync + UnwindSafe + ?Sized

impl<T> Erased for T

impl<T> Same for T

type Output = T

Should always be Self