[][src]Struct nimiq_block::Block

pub struct Block {
    pub header: BlockHeader,
    pub interlink: BlockInterlink,
    pub body: Option<BlockBody>,
}

Fields

header: BlockHeaderinterlink: BlockInterlinkbody: Option<BlockBody>

Methods

impl Block[src]

pub const VERSION: u16[src]

pub const MAX_SIZE: usize[src]

pub fn verify(
    &self,
    timestamp_now: u64,
    network_id: NetworkId,
    genesis_hash: Blake2bHash
) -> Result<(), BlockError>
[src]

pub fn is_immediate_successor_of(&self, predecessor: &Block) -> bool[src]

pub fn into_light(self) -> Block[src]

pub fn is_light(&self) -> bool[src]

Trait Implementations

impl Clone for Block[src]

impl Default for Block[src]

impl Eq for Block[src]

impl Ord for Block[src]

impl PartialEq<Block> for Block[src]

impl PartialOrd<Block> for Block[src]

impl Debug for Block[src]

impl StructuralPartialEq for Block[src]

impl StructuralEq for Block[src]

impl Deserialize for Block[src]

impl Serialize for Block[src]

Auto Trait Implementations

impl Send for Block

impl Sync for Block

impl Unpin for Block

impl UnwindSafe for Block

impl RefUnwindSafe for Block

Blanket Implementations

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

impl<T> From<T> 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<T> Borrow<T> for T where
    T: ?Sized
[src]

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

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

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> Clear for T where
    T: InitializableFromZeroed + ?Sized

impl<T> InitializableFromZeroed for T where
    T: Default

impl<T> Erased for T