Struct snarkvm_polycommit::data_structures::LabeledCommitment [−][src]
pub struct LabeledCommitment<C: PCCommitment> { /* fields omitted */ }
Expand description
A commitment along with information about its degree bound (if any).
Implementations
impl<C: PCCommitment> LabeledCommitment<C>
[src]
impl<C: PCCommitment> LabeledCommitment<C>
[src]pub fn new(
label: PolynomialLabel,
commitment: C,
degree_bound: Option<usize>
) -> Self
[src]
pub fn new(
label: PolynomialLabel,
commitment: C,
degree_bound: Option<usize>
) -> Self
[src]Instantiate a new polynomial_context.
pub fn commitment(&self) -> &C
[src]
pub fn commitment(&self) -> &C
[src]Retrieve the commitment from self
.
pub fn degree_bound(&self) -> Option<usize>
[src]
pub fn degree_bound(&self) -> Option<usize>
[src]Retrieve the degree bound in self
.
Trait Implementations
impl<TargetCurve, BaseCurve, PG> AllocGadget<LabeledCommitment<Commitment<TargetCurve>>, <BaseCurve as PairingEngine>::Fr> for LabeledCommitmentVar<TargetCurve, BaseCurve, PG> where
TargetCurve: PairingEngine,
BaseCurve: PairingEngine,
PG: PairingGadget<TargetCurve, <BaseCurve as PairingEngine>::Fr>,
<TargetCurve as PairingEngine>::G1Affine: ToConstraintField<<BaseCurve as PairingEngine>::Fr>,
<TargetCurve as PairingEngine>::G2Affine: ToConstraintField<<BaseCurve as PairingEngine>::Fr>,
[src]
impl<TargetCurve, BaseCurve, PG> AllocGadget<LabeledCommitment<Commitment<TargetCurve>>, <BaseCurve as PairingEngine>::Fr> for LabeledCommitmentVar<TargetCurve, BaseCurve, PG> where
TargetCurve: PairingEngine,
BaseCurve: PairingEngine,
PG: PairingGadget<TargetCurve, <BaseCurve as PairingEngine>::Fr>,
<TargetCurve as PairingEngine>::G1Affine: ToConstraintField<<BaseCurve as PairingEngine>::Fr>,
<TargetCurve as PairingEngine>::G2Affine: ToConstraintField<<BaseCurve as PairingEngine>::Fr>,
[src]fn alloc_constant<Fn: FnOnce() -> Result<T, SynthesisError>, T: Borrow<LabeledCommitment<Commitment<TargetCurve>>>, CS: ConstraintSystem<<BaseCurve as PairingEngine>::Fr>>(
cs: CS,
value_gen: Fn
) -> Result<Self, SynthesisError>
[src]
cs: CS,
value_gen: Fn
) -> Result<Self, SynthesisError>
fn alloc<Fn: FnOnce() -> Result<T, SynthesisError>, T: Borrow<LabeledCommitment<Commitment<TargetCurve>>>, CS: ConstraintSystem<<BaseCurve as PairingEngine>::Fr>>(
cs: CS,
value_gen: Fn
) -> Result<Self, SynthesisError>
[src]
cs: CS,
value_gen: Fn
) -> Result<Self, SynthesisError>
fn alloc_input<Fn: FnOnce() -> Result<T, SynthesisError>, T: Borrow<LabeledCommitment<Commitment<TargetCurve>>>, CS: ConstraintSystem<<BaseCurve as PairingEngine>::Fr>>(
cs: CS,
value_gen: Fn
) -> Result<Self, SynthesisError>
[src]
cs: CS,
value_gen: Fn
) -> Result<Self, SynthesisError>
fn alloc_checked<Fn, T, CS>(cs: CS, f: Fn) -> Result<Self, SynthesisError> where
Fn: FnOnce() -> Result<T, SynthesisError>,
CS: ConstraintSystem<F>,
T: Borrow<V>,
[src]
Fn: FnOnce() -> Result<T, SynthesisError>,
CS: ConstraintSystem<F>,
T: Borrow<V>,
fn alloc_input_checked<Fn, T, CS>(cs: CS, f: Fn) -> Result<Self, SynthesisError> where
Fn: FnOnce() -> Result<T, SynthesisError>,
CS: ConstraintSystem<F>,
T: Borrow<V>,
[src]
Fn: FnOnce() -> Result<T, SynthesisError>,
CS: ConstraintSystem<F>,
T: Borrow<V>,
impl<C: PCCommitment> CanonicalSerialize for LabeledCommitment<C>
[src]
impl<C: PCCommitment> CanonicalSerialize for LabeledCommitment<C>
[src]fn serialize<W: Write>(&self, writer: &mut W) -> Result<(), SerializationError>
[src]
fn serialize<W: Write>(&self, writer: &mut W) -> Result<(), SerializationError>
[src]Serializes self
into writer
.
fn serialized_size(&self) -> usize
[src]
fn serialize_uncompressed<W: Write>(
&self,
writer: &mut W
) -> Result<(), SerializationError>
[src]
fn serialize_uncompressed<W: Write>(
&self,
writer: &mut W
) -> Result<(), SerializationError>
[src]Serializes self
into writer
without compression.
fn uncompressed_size(&self) -> usize
[src]
impl<C: Clone + PCCommitment> Clone for LabeledCommitment<C>
[src]
impl<C: Clone + PCCommitment> Clone for LabeledCommitment<C>
[src]fn clone(&self) -> LabeledCommitment<C>
[src]
fn clone(&self) -> LabeledCommitment<C>
[src]Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]Performs copy-assignment from source
. Read more
impl<C: PCCommitment> ToBytes for LabeledCommitment<C>
[src]
impl<C: PCCommitment> ToBytes for LabeledCommitment<C>
[src]impl<F: Field, C: PCCommitment + ToConstraintField<F>> ToConstraintField<F> for LabeledCommitment<C>
[src]
impl<F: Field, C: PCCommitment + ToConstraintField<F>> ToConstraintField<F> for LabeledCommitment<C>
[src]fn to_field_elements(&self) -> Result<Vec<F>, ConstraintFieldError>
[src]
Auto Trait Implementations
impl<C> RefUnwindSafe for LabeledCommitment<C> where
C: RefUnwindSafe,
C: RefUnwindSafe,
impl<C> Send for LabeledCommitment<C> where
C: Send,
C: Send,
impl<C> Sync for LabeledCommitment<C> where
C: Sync,
C: Sync,
impl<C> Unpin for LabeledCommitment<C> where
C: Unpin,
C: Unpin,
impl<C> UnwindSafe for LabeledCommitment<C> where
C: UnwindSafe,
C: UnwindSafe,
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> Pointable for T
impl<T> Pointable for T
impl<T> Same<T> for T
impl<T> Same<T> for T
type Output = T
type Output = T
Should always be Self
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,