pub struct PedersenHashTree<'a, E: JubjubEngine> { /* private fields */ }Trait Implementations§
Source§impl<'a, E: JubjubEngine> MerkleTree<E> for PedersenHashTree<'a, E>
impl<'a, E: JubjubEngine> MerkleTree<E> for PedersenHashTree<'a, E>
type Hash = AllocatedNum<E>
fn path_bits_per_level(&self) -> usize
fn branching_factor(&self) -> usize
fn hash_leaf<CS: ConstraintSystem<E>>( &self, cs: CS, leaf: &[Boolean], ) -> Result<Self::Hash, SynthesisError>
fn hash_node<CS: ConstraintSystem<E>>( &self, cs: CS, children: &[Self::Hash], level: usize, ) -> Result<Self::Hash, SynthesisError>
fn check_inclusion<CS: ConstraintSystem<E>>( &self, cs: CS, leaf: &[Boolean], path: &[Boolean], witness: &[Self::Hash], ) -> Result<Boolean, SynthesisError>
fn check_inclusion_for_root<CS: ConstraintSystem<E>>( &self, cs: CS, root: &Self::Hash, leaf: &[Boolean], path: &[Boolean], witness: &[Self::Hash], ) -> Result<Boolean, SynthesisError>
fn check_hash_inclusion<CS: ConstraintSystem<E>>( &self, cs: CS, hash: &Self::Hash, path: &[Boolean], witness: &[Self::Hash], ) -> Result<Boolean, SynthesisError>
fn check_hash_inclusion_for_root<CS: ConstraintSystem<E>>( &self, cs: CS, root: &Self::Hash, hash: &Self::Hash, path: &[Boolean], witness: &[Self::Hash], ) -> Result<Boolean, SynthesisError>
fn update<CS: ConstraintSystem<E>>( &mut self, cs: CS, leaf: &[Boolean], path: &[Boolean], witness: &[Self::Hash], ) -> Result<Self::Hash, SynthesisError>
fn update_from_hash<CS: ConstraintSystem<E>>( &mut self, cs: CS, hash: &Self::Hash, path: &[Boolean], witness: &[Self::Hash], ) -> Result<Self::Hash, SynthesisError>
fn update_intersect<CS: ConstraintSystem<E>>( &mut self, cs: CS, leafs: (&[Boolean], &[Boolean]), paths: (&[Boolean], &[Boolean]), witnesses: (&[Self::Hash], &[Self::Hash]), ) -> Result<Self::Hash, SynthesisError>
fn update_from_hash_intersect<CS: ConstraintSystem<E>>( &mut self, cs: CS, leafs: (&Self::Hash, &Self::Hash), paths: (&[Boolean], &[Boolean]), witnesses: (&[Self::Hash], &[Self::Hash]), ) -> Result<Self::Hash, SynthesisError>
Auto Trait Implementations§
impl<'a, E> Freeze for PedersenHashTree<'a, E>
impl<'a, E> RefUnwindSafe for PedersenHashTree<'a, E>
impl<'a, E> Send for PedersenHashTree<'a, E>
impl<'a, E> Sync for PedersenHashTree<'a, E>
impl<'a, E> Unpin for PedersenHashTree<'a, E>
impl<'a, E> UnwindSafe for PedersenHashTree<'a, E>
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