pub struct HeaderDigest(/* private fields */);
Implementations§
Source§impl HeaderDigest
impl HeaderDigest
Sourcepub fn calc_mmr_hash(&self) -> Byte32
pub fn calc_mmr_hash(&self) -> Byte32
Source§impl HeaderDigest
impl HeaderDigest
Sourcepub fn is_default(&self) -> bool
pub fn is_default(&self) -> bool
Checks if the HeaderDigest
is the default value.
Source§impl HeaderDigest
impl HeaderDigest
pub const TOTAL_SIZE: usize = 120usize
pub const FIELD_SIZES: [usize; 10] = _
pub const FIELD_COUNT: usize = 10usize
pub fn children_hash(&self) -> Byte32
pub fn total_difficulty(&self) -> Uint256
pub fn start_number(&self) -> Uint64
pub fn end_number(&self) -> Uint64
pub fn start_epoch(&self) -> Uint64
pub fn end_epoch(&self) -> Uint64
pub fn start_timestamp(&self) -> Uint64
pub fn end_timestamp(&self) -> Uint64
pub fn start_compact_target(&self) -> Uint32
pub fn end_compact_target(&self) -> Uint32
pub fn as_reader<'r>(&'r self) -> HeaderDigestReader<'r>
Trait Implementations§
Source§impl Clone for HeaderDigest
impl Clone for HeaderDigest
Source§fn clone(&self) -> HeaderDigest
fn clone(&self) -> HeaderDigest
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for HeaderDigest
impl Debug for HeaderDigest
Source§impl Default for HeaderDigest
impl Default for HeaderDigest
Source§impl Display for HeaderDigest
impl Display for HeaderDigest
Source§impl Entity for HeaderDigest
impl Entity for HeaderDigest
const NAME: &'static str = "HeaderDigest"
type Builder = HeaderDigestBuilder
fn new_unchecked(data: Bytes) -> Self
fn as_bytes(&self) -> Bytes
fn as_slice(&self) -> &[u8] ⓘ
fn from_slice(slice: &[u8]) -> VerificationResult<Self>
fn from_compatible_slice(slice: &[u8]) -> VerificationResult<Self>
fn new_builder() -> Self::Builder
fn as_builder(self) -> Self::Builder
Source§impl Hash for HeaderDigest
impl Hash for HeaderDigest
Source§impl LowerHex for HeaderDigest
impl LowerHex for HeaderDigest
Source§impl PartialEq for HeaderDigest
impl PartialEq for HeaderDigest
impl Eq for HeaderDigest
Auto Trait Implementations§
impl !Freeze for HeaderDigest
impl RefUnwindSafe for HeaderDigest
impl Send for HeaderDigest
impl Sync for HeaderDigest
impl Unpin for HeaderDigest
impl UnwindSafe for HeaderDigest
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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)Source§impl<T> PackVec<HeaderDigestVec, HeaderDigest> for Twhere
T: IntoIterator<Item = HeaderDigest>,
impl<T> PackVec<HeaderDigestVec, HeaderDigest> for Twhere
T: IntoIterator<Item = HeaderDigest>,
Source§fn pack(self) -> HeaderDigestVec
fn pack(self) -> HeaderDigestVec
Packs a vector of binary data into one binary data.