Struct snarkvm_algorithms::snark::groth16::ProvingKey
source · [−]pub struct ProvingKey<E: PairingEngine> {
pub vk: VerifyingKey<E>,
pub beta_g1: E::G1Affine,
pub delta_g1: E::G1Affine,
pub a_query: Vec<E::G1Affine>,
pub b_g1_query: Vec<E::G1Affine>,
pub b_g2_query: Vec<E::G2Affine>,
pub h_query: Vec<E::G1Affine>,
pub l_query: Vec<E::G1Affine>,
}
Expand description
Full public (prover and verifier) parameters for the Groth16 zkSNARK.
Fields
vk: VerifyingKey<E>
beta_g1: E::G1Affine
delta_g1: E::G1Affine
a_query: Vec<E::G1Affine>
b_g1_query: Vec<E::G1Affine>
b_g2_query: Vec<E::G2Affine>
h_query: Vec<E::G1Affine>
l_query: Vec<E::G1Affine>
Implementations
sourceimpl<E: PairingEngine> ProvingKey<E>
impl<E: PairingEngine> ProvingKey<E>
Trait Implementations
sourceimpl<E: PairingEngine> CanonicalDeserialize for ProvingKey<E>
impl<E: PairingEngine> CanonicalDeserialize for ProvingKey<E>
sourcefn deserialize<R: Read>(reader: &mut R) -> Result<Self, SerializationError>
fn deserialize<R: Read>(reader: &mut R) -> Result<Self, SerializationError>
Reads Self
from reader
.
sourcefn deserialize_uncompressed<R: Read>(
reader: &mut R
) -> Result<Self, SerializationError>
fn deserialize_uncompressed<R: Read>(
reader: &mut R
) -> Result<Self, SerializationError>
Reads Self
from reader
without compression.
sourceimpl<E: PairingEngine> CanonicalSerialize for ProvingKey<E>
impl<E: PairingEngine> CanonicalSerialize for ProvingKey<E>
sourcefn serialize<W: Write>(&self, writer: &mut W) -> Result<(), SerializationError>
fn serialize<W: Write>(&self, writer: &mut W) -> Result<(), SerializationError>
Serializes self
into writer
.
fn serialized_size(&self) -> usize
sourcefn serialize_uncompressed<W: Write>(
&self,
writer: &mut W
) -> Result<(), SerializationError>
fn serialize_uncompressed<W: Write>(
&self,
writer: &mut W
) -> Result<(), SerializationError>
Serializes self
into writer
without compression.
fn uncompressed_size(&self) -> usize
sourceimpl<E: Clone + PairingEngine> Clone for ProvingKey<E> where
E::G1Affine: Clone,
E::G1Affine: Clone,
E::G1Affine: Clone,
E::G1Affine: Clone,
E::G2Affine: Clone,
E::G1Affine: Clone,
E::G1Affine: Clone,
impl<E: Clone + PairingEngine> Clone for ProvingKey<E> where
E::G1Affine: Clone,
E::G1Affine: Clone,
E::G1Affine: Clone,
E::G1Affine: Clone,
E::G2Affine: Clone,
E::G1Affine: Clone,
E::G1Affine: Clone,
sourcefn clone(&self) -> ProvingKey<E>
fn clone(&self) -> ProvingKey<E>
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl<E: Debug + PairingEngine> Debug for ProvingKey<E> where
E::G1Affine: Debug,
E::G1Affine: Debug,
E::G1Affine: Debug,
E::G1Affine: Debug,
E::G2Affine: Debug,
E::G1Affine: Debug,
E::G1Affine: Debug,
impl<E: Debug + PairingEngine> Debug for ProvingKey<E> where
E::G1Affine: Debug,
E::G1Affine: Debug,
E::G1Affine: Debug,
E::G1Affine: Debug,
E::G2Affine: Debug,
E::G1Affine: Debug,
E::G1Affine: Debug,
sourceimpl<E: PairingEngine> From<ProvingKey<E>> for VerifyingKey<E>
impl<E: PairingEngine> From<ProvingKey<E>> for VerifyingKey<E>
sourcefn from(other: ProvingKey<E>) -> Self
fn from(other: ProvingKey<E>) -> Self
Performs the conversion.
sourceimpl<E: PairingEngine> From<ProvingKey<E>> for PreparedVerifyingKey<E>
impl<E: PairingEngine> From<ProvingKey<E>> for PreparedVerifyingKey<E>
sourcefn from(other: ProvingKey<E>) -> Self
fn from(other: ProvingKey<E>) -> Self
Performs the conversion.
sourceimpl<E: PairingEngine> FromBytes for ProvingKey<E>
impl<E: PairingEngine> FromBytes for ProvingKey<E>
sourceimpl<E: PartialEq + PairingEngine> PartialEq<ProvingKey<E>> for ProvingKey<E> where
E::G1Affine: PartialEq,
E::G1Affine: PartialEq,
E::G1Affine: PartialEq,
E::G1Affine: PartialEq,
E::G2Affine: PartialEq,
E::G1Affine: PartialEq,
E::G1Affine: PartialEq,
impl<E: PartialEq + PairingEngine> PartialEq<ProvingKey<E>> for ProvingKey<E> where
E::G1Affine: PartialEq,
E::G1Affine: PartialEq,
E::G1Affine: PartialEq,
E::G1Affine: PartialEq,
E::G2Affine: PartialEq,
E::G1Affine: PartialEq,
E::G1Affine: PartialEq,
sourcefn eq(&self, other: &ProvingKey<E>) -> bool
fn eq(&self, other: &ProvingKey<E>) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &ProvingKey<E>) -> bool
fn ne(&self, other: &ProvingKey<E>) -> bool
This method tests for !=
.
sourceimpl<E: PairingEngine> ToBytes for ProvingKey<E>
impl<E: PairingEngine> ToBytes for ProvingKey<E>
impl<E: PairingEngine> StructuralPartialEq for ProvingKey<E>
Auto Trait Implementations
impl<E> RefUnwindSafe for ProvingKey<E> where
<E as PairingEngine>::G1Affine: RefUnwindSafe,
<E as PairingEngine>::G2Affine: RefUnwindSafe,
impl<E> Send for ProvingKey<E>
impl<E> Sync for ProvingKey<E>
impl<E> Unpin for ProvingKey<E> where
<E as PairingEngine>::G1Affine: Unpin,
<E as PairingEngine>::G2Affine: Unpin,
impl<E> UnwindSafe for ProvingKey<E> where
<E as PairingEngine>::G1Affine: UnwindSafe,
<E as PairingEngine>::G2Affine: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<T> Pointable for T
impl<T> Pointable for T
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcepub fn to_owned(&self) -> T
pub fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
sourcepub fn clone_into(&self, target: &mut T)
pub fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more