pub struct BlockInfo {Show 13 fields
pub id: BlockHash,
pub height: u32,
pub version: Version,
pub timestamp: u64,
pub tx_count: u64,
pub size: usize,
pub weight: u64,
pub merkle_root: TxMerkleNode,
pub previousblockhash: Option<BlockHash>,
pub mediantime: u64,
pub nonce: u32,
pub bits: CompactTarget,
pub difficulty: f64,
}Expand description
Information about a bitcoin Block.
Fields§
§id: BlockHash§height: u32The Block’s height.
version: VersionThe Block’s version.
timestamp: u64The Block’s UNIX timestamp.
tx_count: u64The Block’s Transaction count.
size: usizeThe Block’s size, in bytes.
weight: u64The Block’s weight.
merkle_root: TxMerkleNodeThe Merkle root of the transactions in the block.
previousblockhash: Option<BlockHash>§mediantime: u64The Block’s MTP (Median Time Past).
nonce: u32The Block’s nonce value.
bits: CompactTargetThe Block’s bits value as a CompactTarget.
difficulty: f64The Block’s difficulty target value.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for BlockInfo
impl<'de> Deserialize<'de> for BlockInfo
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for BlockInfo
Auto Trait Implementations§
impl Freeze for BlockInfo
impl RefUnwindSafe for BlockInfo
impl Send for BlockInfo
impl Sync for BlockInfo
impl Unpin for BlockInfo
impl UnsafeUnpin for BlockInfo
impl UnwindSafe for BlockInfo
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more