pub struct Entry<V: Version> { /* private fields */ }Expand description
MMR Entry.
Implementations§
Source§impl<V: Version> Entry<V>
impl<V: Version> Entry<V>
Sourcepub fn new(data: V::NodeData, left: EntryLink, right: EntryLink) -> Self
pub fn new(data: V::NodeData, left: EntryLink, right: EntryLink) -> Self
New entry of type node.
Sourcepub fn leaf_count(&self) -> u64
pub fn leaf_count(&self) -> u64
Number of leaves under this node.
§Panics
Panics if this entry was constructed with a descending height range or
a range containing more leaves than can be represented by a u64.
Entries produced by Self::read are validated against these cases.
Trait Implementations§
Auto Trait Implementations§
impl<V> Freeze for Entry<V>
impl<V> RefUnwindSafe for Entry<V>
impl<V> Send for Entry<V>
impl<V> Sync for Entry<V>
impl<V> Unpin for Entry<V>
impl<V> UnsafeUnpin for Entry<V>
impl<V> UnwindSafe for Entry<V>
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