[−][src]Trait sapling_crypto_ce::circuit::merkle::MerkleTree
Associated Types
type Hash
Required methods
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>
&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>
&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>
&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>
&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>
&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>
&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>
&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>
&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>
&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>
&mut self,
cs: CS,
leafs: (&Self::Hash, &Self::Hash),
paths: (&[Boolean], &[Boolean]),
witnesses: (&[Self::Hash], &[Self::Hash])
) -> Result<Self::Hash, SynthesisError>
Implementors
impl<'a, E: JubjubEngine> MerkleTree<E> for PedersenHashTree<'a, E>
[src]
type Hash = AllocatedNum<E>
fn path_bits_per_level(&self) -> usize
[src]
fn branching_factor(&self) -> usize
[src]
fn hash_leaf<CS: ConstraintSystem<E>>(
&self,
cs: CS,
leaf: &[Boolean]
) -> Result<Self::Hash, SynthesisError>
[src]
&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>
[src]
&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>
[src]
&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>
[src]
&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>
[src]
&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>
[src]
&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>
[src]
&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>
[src]
&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>
[src]
&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>
[src]
&mut self,
cs: CS,
leafs: (&Self::Hash, &Self::Hash),
paths: (&[Boolean], &[Boolean]),
witnesses: (&[Self::Hash], &[Self::Hash])
) -> Result<Self::Hash, SynthesisError>
impl<'a, E: PoseidonEngine<SBox = QuinticSBox<E>>> MerkleTree<E> for PoseidonHashTree<'a, E>
[src]
type Hash = AllocatedNum<E>
fn path_bits_per_level(&self) -> usize
[src]
fn branching_factor(&self) -> usize
[src]
fn hash_leaf<CS: ConstraintSystem<E>>(
&self,
cs: CS,
leaf: &[Boolean]
) -> Result<Self::Hash, SynthesisError>
[src]
&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>
[src]
&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>
[src]
&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>
[src]
&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>
[src]
&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>
[src]
&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>
[src]
&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>
[src]
&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>
[src]
&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>
[src]
&mut self,
cs: CS,
leafs: (&Self::Hash, &Self::Hash),
paths: (&[Boolean], &[Boolean]),
witnesses: (&[Self::Hash], &[Self::Hash])
) -> Result<Self::Hash, SynthesisError>