Struct bellman::TestConstraintSystem
[−]
[src]
pub struct TestConstraintSystem<E: Engine> { /* fields omitted */ }
Constraint system for testing purposes.
Methods
impl<E: Engine> TestConstraintSystem<E>
[src]
fn new() -> TestConstraintSystem<E>
[src]
fn is_satisfied(&self) -> bool
[src]
fn assign(&mut self, path: &str, to: E::Fr)
[src]
fn get(&mut self, path: &str) -> E::Fr
[src]
Trait Implementations
impl<E: Engine> PublicConstraintSystem<E> for TestConstraintSystem<E>
[src]
fn alloc_input<NR, N, F>(&mut self, name_fn: N, f: F) -> Result<Variable, Error> where
NR: Into<String>,
N: FnOnce() -> NR,
F: FnOnce() -> Result<E::Fr, Error>,
[src]
NR: Into<String>,
N: FnOnce() -> NR,
F: FnOnce() -> Result<E::Fr, Error>,
Allocate a public input that the verifier knows. The provided function is used to determine the assignment of the variable. Read more
impl<E: Engine> ConstraintSystem<E> for TestConstraintSystem<E>
[src]
fn alloc<NR, N, F>(&mut self, name_fn: N, f: F) -> Result<Variable, Error> where
NR: Into<String>,
N: FnOnce() -> NR,
F: FnOnce() -> Result<E::Fr, Error>,
[src]
NR: Into<String>,
N: FnOnce() -> NR,
F: FnOnce() -> Result<E::Fr, Error>,
Allocate a private variable in the constraint system. The provided function is used to determine the assignment of the variable. Read more
fn enforce<NR: Into<String>, N: FnOnce() -> NR>(
&mut self,
name_fn: N,
a: LinearCombination<E>,
b: LinearCombination<E>,
c: LinearCombination<E>
)
[src]
&mut self,
name_fn: N,
a: LinearCombination<E>,
b: LinearCombination<E>,
c: LinearCombination<E>
)
Enforce that A
* B
= C
.
fn namespace<NR, N, R, F>(
&mut self,
name_fn: N,
space_fn: F
) -> Result<R, Error> where
NR: Into<String>,
N: FnOnce() -> NR,
F: FnOnce(&mut Self) -> Result<R, Error>,
[src]
&mut self,
name_fn: N,
space_fn: F
) -> Result<R, Error> where
NR: Into<String>,
N: FnOnce() -> NR,
F: FnOnce(&mut Self) -> Result<R, Error>,
Begin a namespace for the constraint system
fn one() -> Variable
[src]
Return the "one" input variable