[−][src]Trait snarkos_models::gadgets::utilities::select::CondSelectGadget
If condition is true
, return first
; else, select second
.
Required methods
fn conditionally_select<CS: ConstraintSystem<F>>(
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
fn cost() -> usize
Implementors
impl<F: PrimeField> CondSelectGadget<F> for Boolean
[src]
fn conditionally_select<CS>(
cs: CS,
cond: &Self,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError> where
CS: ConstraintSystem<F>,
[src]
cs: CS,
cond: &Self,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError> where
CS: ConstraintSystem<F>,
fn cost() -> usize
[src]
impl<F: PrimeField> CondSelectGadget<F> for FpGadget<F>
[src]
fn conditionally_select<CS: ConstraintSystem<F>>(
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
[src]
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
fn cost() -> usize
[src]
impl<F: PrimeField> CondSelectGadget<F> for AllocatedBit
[src]
fn conditionally_select<CS: ConstraintSystem<F>>(
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
[src]
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
fn cost() -> usize
[src]
impl<F: PrimeField> CondSelectGadget<F> for UInt128
[src]
fn conditionally_select<CS: ConstraintSystem<F>>(
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
[src]
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
fn cost() -> usize
[src]
impl<F: PrimeField> CondSelectGadget<F> for UInt8
[src]
fn conditionally_select<CS: ConstraintSystem<F>>(
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
[src]
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
fn cost() -> usize
[src]
impl<F: PrimeField> CondSelectGadget<F> for UInt16
[src]
fn conditionally_select<CS: ConstraintSystem<F>>(
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
[src]
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
fn cost() -> usize
[src]
impl<F: PrimeField> CondSelectGadget<F> for UInt32
[src]
fn conditionally_select<CS: ConstraintSystem<F>>(
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
[src]
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
fn cost() -> usize
[src]
impl<F: PrimeField> CondSelectGadget<F> for UInt64
[src]
fn conditionally_select<CS: ConstraintSystem<F>>(
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
[src]
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
fn cost() -> usize
[src]
impl<P, F: PrimeField> CondSelectGadget<F> for Fp6Gadget<P, F> where
P: Fp6Parameters,
P::Fp2Params: Fp2Parameters<Fp = F>,
[src]
P: Fp6Parameters,
P::Fp2Params: Fp2Parameters<Fp = F>,
fn conditionally_select<CS: ConstraintSystem<F>>(
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
[src]
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
fn cost() -> usize
[src]
impl<P, F: PrimeField> CondSelectGadget<F> for Fp12Gadget<P, F> where
P: Fp12Parameters,
<P::Fp6Params as Fp6Parameters>::Fp2Params: Fp2Parameters<Fp = F>,
[src]
P: Fp12Parameters,
<P::Fp6Params as Fp6Parameters>::Fp2Params: Fp2Parameters<Fp = F>,
fn conditionally_select<CS: ConstraintSystem<F>>(
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
[src]
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
fn cost() -> usize
[src]
impl<P: Fp2Parameters<Fp = F>, F: PrimeField> CondSelectGadget<F> for Fp2Gadget<P, F>
[src]
fn conditionally_select<CS: ConstraintSystem<F>>(
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>
[src]
cs: CS,
cond: &Boolean,
first: &Self,
second: &Self
) -> Result<Self, SynthesisError>