#[repr(C)]pub struct ChangelogEntry<const HEIGHT: usize> {
pub root: [u8; 32],
pub path: [[u8; 32]; HEIGHT],
pub index: u64,
}
Fields§
§root: [u8; 32]
Root.
path: [[u8; 32]; HEIGHT]
§index: u64
Implementations§
source§impl<const HEIGHT: usize> ChangelogEntry<HEIGHT>
impl<const HEIGHT: usize> ChangelogEntry<HEIGHT>
pub fn new(root: [u8; 32], path: [[u8; 32]; HEIGHT], index: usize) -> Self
pub fn default_with_index(index: usize) -> Self
pub fn index(&self) -> usize
pub fn update_proof( &self, leaf_index: usize, proof: &mut BoundedVec<'_, [u8; 32]>, _allow_updates_in_changelog: bool ) -> Result<(), ConcurrentMerkleTreeError>
pub fn update_subtrees( &self, rightmost_index: usize, subtrees: &mut BoundedVec<'_, [u8; 32]> )
Trait Implementations§
source§impl<const HEIGHT: usize> Clone for ChangelogEntry<HEIGHT>
impl<const HEIGHT: usize> Clone for ChangelogEntry<HEIGHT>
source§fn clone(&self) -> ChangelogEntry<HEIGHT>
fn clone(&self) -> ChangelogEntry<HEIGHT>
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<const HEIGHT: usize> Debug for ChangelogEntry<HEIGHT>
impl<const HEIGHT: usize> Debug for ChangelogEntry<HEIGHT>
source§impl<const HEIGHT: usize> PartialEq for ChangelogEntry<HEIGHT>
impl<const HEIGHT: usize> PartialEq for ChangelogEntry<HEIGHT>
source§fn eq(&self, other: &ChangelogEntry<HEIGHT>) -> bool
fn eq(&self, other: &ChangelogEntry<HEIGHT>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl<const HEIGHT: usize> Eq for ChangelogEntry<HEIGHT>
impl<const HEIGHT: usize> Pod for ChangelogEntry<HEIGHT>
impl<const HEIGHT: usize> StructuralPartialEq for ChangelogEntry<HEIGHT>
Auto Trait Implementations§
impl<const HEIGHT: usize> Freeze for ChangelogEntry<HEIGHT>
impl<const HEIGHT: usize> RefUnwindSafe for ChangelogEntry<HEIGHT>
impl<const HEIGHT: usize> Send for ChangelogEntry<HEIGHT>
impl<const HEIGHT: usize> Sync for ChangelogEntry<HEIGHT>
impl<const HEIGHT: usize> Unpin for ChangelogEntry<HEIGHT>
impl<const HEIGHT: usize> UnwindSafe for ChangelogEntry<HEIGHT>
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
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