pub struct AddressMerkleTreeBundle {
pub rollover_fee: i64,
pub merkle_tree: IndexedMerkleTreeVersion,
pub accounts: AddressMerkleTreeAccounts,
pub queue_elements: Vec<[u8; 32]>,
/* private fields */
}Fields§
§rollover_fee: i64§merkle_tree: IndexedMerkleTreeVersion§accounts: AddressMerkleTreeAccounts§queue_elements: Vec<[u8; 32]>Implementations§
Source§impl AddressMerkleTreeBundle
impl AddressMerkleTreeBundle
pub fn new_v1(accounts: AddressMerkleTreeAccounts) -> Result<Self, IndexerError>
pub fn new_v2(accounts: AddressMerkleTreeAccounts) -> Result<Self, IndexerError>
pub fn get_v1_indexed_merkle_tree( &self, ) -> Option<&IndexedMerkleTree<Poseidon, usize>>
pub fn get_v1_indexed_merkle_tree_mut( &mut self, ) -> Option<&mut IndexedMerkleTree<Poseidon, usize>>
pub fn get_v2_indexed_merkle_tree( &self, ) -> Option<&IndexedMerkleTree<Poseidon, usize>>
pub fn get_v2_indexed_merkle_tree_mut( &mut self, ) -> Option<&mut IndexedMerkleTree<Poseidon, usize>>
pub fn get_subtrees(&self) -> Vec<[u8; 32]>
pub fn root(&self) -> [u8; 32]
pub fn find_low_element_for_nonexistent( &self, value: &BigUint, ) -> Result<(IndexedElement<usize>, BigUint), IndexerError>
pub fn new_element_with_low_element_index( &self, index: usize, value: &BigUint, ) -> Result<IndexedElementBundle<usize>, IndexerError>
pub fn get_proof_of_leaf( &self, index: usize, full: bool, ) -> Result<Vec<[u8; 32]>, IndexerError>
pub fn append(&mut self, value: &BigUint) -> Result<(), IndexerError>
pub fn get_non_inclusion_proof_inputs( &self, value: &[u8; 32], ) -> Result<NonInclusionMerkleProofInputs, IndexerError>
pub fn right_most_index(&self) -> usize
pub fn append_with_low_element_index( &mut self, index: usize, value: &BigUint, ) -> Result<IndexedElementBundle<usize>, IndexerError>
pub fn sequence_number(&self) -> u64
pub fn height(&self) -> usize
pub fn get_path_of_leaf( &self, index: usize, full: bool, ) -> Result<Vec<[u8; 32]>, IndexerError>
pub fn indexed_array_v1(&self) -> Option<&IndexedArray<Poseidon, usize>>
pub fn indexed_array_v2(&self) -> Option<&IndexedArray<Poseidon, usize>>
pub fn update( &mut self, new_low_element: &IndexedElement<usize>, new_element: &IndexedElement<usize>, new_element_next_value: &BigUint, ) -> Result<(), IndexerError>
Trait Implementations§
Source§impl Clone for AddressMerkleTreeBundle
impl Clone for AddressMerkleTreeBundle
Source§fn clone(&self) -> AddressMerkleTreeBundle
fn clone(&self) -> AddressMerkleTreeBundle
Returns a duplicate 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 moreAuto Trait Implementations§
impl Freeze for AddressMerkleTreeBundle
impl RefUnwindSafe for AddressMerkleTreeBundle
impl Send for AddressMerkleTreeBundle
impl Sync for AddressMerkleTreeBundle
impl Unpin for AddressMerkleTreeBundle
impl UnwindSafe for AddressMerkleTreeBundle
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