pub struct LabeledPolynomial<F: Field, P: Polynomial<F>> { /* private fields */ }
Expand description
A polynomial along with information about its degree bound (if any), and the maximum number of queries that will be made to it. This latter number determines the amount of protection that will be provided to a commitment for this polynomial.
Implementations§
source§impl<'a, F: Field, P: Polynomial<F>> LabeledPolynomial<F, P>
impl<'a, F: Field, P: Polynomial<F>> LabeledPolynomial<F, P>
sourcepub fn new(
label: PolynomialLabel,
polynomial: P,
degree_bound: Option<usize>,
hiding_bound: Option<usize>
) -> Self
pub fn new( label: PolynomialLabel, polynomial: P, degree_bound: Option<usize>, hiding_bound: Option<usize> ) -> Self
Construct a new labeled polynomial.
sourcepub fn polynomial(&self) -> &P
pub fn polynomial(&self) -> &P
Retrieve an immutable reference to the polynomial contained in self
.
sourcepub fn polynomial_mut(&mut self) -> &mut P
pub fn polynomial_mut(&mut self) -> &mut P
Retrieve a mutable reference to the polynomial contained in self
sourcepub fn degree_bound(&self) -> Option<usize>
pub fn degree_bound(&self) -> Option<usize>
Retrieve the degree bound in self
.
sourcepub fn hiding_bound(&self) -> Option<usize>
pub fn hiding_bound(&self) -> Option<usize>
Retrieve the hiding bound for the polynomial in self
.
Trait Implementations§
source§impl<F: Field, P: Polynomial<F>> CanonicalDeserialize for LabeledPolynomial<F, P>
impl<F: Field, P: Polynomial<F>> CanonicalDeserialize for LabeledPolynomial<F, P>
source§fn deserialize_with_mode<R: Read>(
reader: R,
compress: Compress,
validate: Validate
) -> Result<Self, SerializationError>
fn deserialize_with_mode<R: Read>( reader: R, compress: Compress, validate: Validate ) -> Result<Self, SerializationError>
The general deserialize method that takes in customization flags.
fn deserialize_compressed<R>(reader: R) -> Result<Self, SerializationError>where R: Read,
fn deserialize_compressed_unchecked<R>( reader: R ) -> Result<Self, SerializationError>where R: Read,
fn deserialize_uncompressed<R>(reader: R) -> Result<Self, SerializationError>where R: Read,
fn deserialize_uncompressed_unchecked<R>( reader: R ) -> Result<Self, SerializationError>where R: Read,
source§impl<F: Field, P: Polynomial<F>> CanonicalSerialize for LabeledPolynomial<F, P>
impl<F: Field, P: Polynomial<F>> CanonicalSerialize for LabeledPolynomial<F, P>
source§fn serialize_with_mode<W: Write>(
&self,
writer: W,
compress: Compress
) -> Result<(), SerializationError>
fn serialize_with_mode<W: Write>( &self, writer: W, compress: Compress ) -> Result<(), SerializationError>
The general serialize method that takes in customization flags.
fn serialized_size(&self, compress: Compress) -> usize
fn serialize_compressed<W>(&self, writer: W) -> Result<(), SerializationError>where W: Write,
fn compressed_size(&self) -> usize
fn serialize_uncompressed<W>(&self, writer: W) -> Result<(), SerializationError>where W: Write,
fn uncompressed_size(&self) -> usize
source§impl<F: Clone + Field, P: Clone + Polynomial<F>> Clone for LabeledPolynomial<F, P>
impl<F: Clone + Field, P: Clone + Polynomial<F>> Clone for LabeledPolynomial<F, P>
source§fn clone(&self) -> LabeledPolynomial<F, P>
fn clone(&self) -> LabeledPolynomial<F, P>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl<F: Debug + Field, P: Debug + Polynomial<F>> Debug for LabeledPolynomial<F, P>
impl<F: Debug + Field, P: Debug + Polynomial<F>> Debug for LabeledPolynomial<F, P>
source§impl<'a, F: Field, P: Polynomial<F>> Deref for LabeledPolynomial<F, P>
impl<'a, F: Field, P: Polynomial<F>> Deref for LabeledPolynomial<F, P>
source§impl<F: Field, P: Polynomial<F>> Valid for LabeledPolynomial<F, P>
impl<F: Field, P: Polynomial<F>> Valid for LabeledPolynomial<F, P>
fn check(&self) -> Result<(), SerializationError>
fn batch_check<'a>( batch: impl Iterator<Item = &'a Self> + Send ) -> Result<(), SerializationError>where Self: 'a,
Auto Trait Implementations§
impl<F, P> RefUnwindSafe for LabeledPolynomial<F, P>where F: RefUnwindSafe, P: RefUnwindSafe,
impl<F, P> Send for LabeledPolynomial<F, P>where P: Send,
impl<F, P> Sync for LabeledPolynomial<F, P>
impl<F, P> Unpin for LabeledPolynomial<F, P>where F: Unpin, P: Unpin,
impl<F, P> UnwindSafe for LabeledPolynomial<F, P>where F: UnwindSafe, P: UnwindSafe,
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