Struct chain_impl_mockchain::header::cstruct::HeaderSlice
source · pub struct HeaderSlice<'a>(&'a [u8]);
Tuple Fields§
§0: &'a [u8]
Implementations§
source§impl<'a> HeaderSlice<'a>
impl<'a> HeaderSlice<'a>
pub fn from_slice(slice: &'a [u8]) -> Result<Self, HeaderError>
pub fn as_slice(&self) -> &'a [u8] ⓘ
pub(super) fn to_owned(&self) -> Header
pub fn version(&self) -> u8
pub fn content_size(&self) -> u32
pub fn date_epoch(&self) -> u32
pub fn date_slotid(&self) -> u32
pub fn height(&self) -> u32
pub fn content_hash_ref(&self) -> &[u8] ⓘ
pub fn content_hash(&self) -> [u8; 32]
pub fn parent_hash_ref(&self) -> &[u8] ⓘ
pub fn parent_hash(&self) -> [u8; 32]
pub fn bft_leader_id_ref(&self) -> &[u8] ⓘ
pub fn bft_leader_id(&self) -> [u8; 32]
pub fn bft_signature_ref(&self) -> &[u8] ⓘ
pub fn bft_signature(&self) -> [u8; 64]
pub fn gp_node_id_ref(&self) -> &[u8] ⓘ
pub fn gp_node_id(&self) -> [u8; 32]
pub fn gp_vrf_proof_ref(&self) -> &[u8] ⓘ
pub fn gp_vrf_proof(&self) -> [u8; 96]
pub fn gp_kes_signature_ref(&self) -> &[u8] ⓘ
pub fn gp_kes_signature(&self) -> [u8; 484]
pub fn slice_bft_auth(self) -> &'a [u8] ⓘ
pub fn slice_gp_auth(self) -> &'a [u8] ⓘ
Auto Trait Implementations§
impl<'a> RefUnwindSafe for HeaderSlice<'a>
impl<'a> Send for HeaderSlice<'a>
impl<'a> Sync for HeaderSlice<'a>
impl<'a> Unpin for HeaderSlice<'a>
impl<'a> UnwindSafe for HeaderSlice<'a>
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