Struct snarkvm_ledger_coinbase::PartialSolution
source · pub struct PartialSolution<N: Network> { /* private fields */ }
Expand description
The partial solution for the coinbase puzzle from a prover.
Implementations§
source§impl<N: Network> PartialSolution<N>
impl<N: Network> PartialSolution<N>
sourcepub fn new<C: Into<PuzzleCommitment<N>>>(
address: Address<N>,
nonce: u64,
commitment: C
) -> Self
pub fn new<C: Into<PuzzleCommitment<N>>>( address: Address<N>, nonce: u64, commitment: C ) -> Self
Initializes a new instance of the partial solution.
sourcepub const fn commitment(&self) -> PuzzleCommitment<N>
pub const fn commitment(&self) -> PuzzleCommitment<N>
Returns the commitment for the solution.
sourcepub fn to_prover_polynomial(
&self,
epoch_challenge: &EpochChallenge<N>
) -> Result<DensePolynomial<<N::PairingCurve as PairingEngine>::Fr>>
pub fn to_prover_polynomial( &self, epoch_challenge: &EpochChallenge<N> ) -> Result<DensePolynomial<<N::PairingCurve as PairingEngine>::Fr>>
Returns the prover polynomial.
Trait Implementations§
source§impl<N: Clone + Network> Clone for PartialSolution<N>
impl<N: Clone + Network> Clone for PartialSolution<N>
source§fn clone(&self) -> PartialSolution<N>
fn clone(&self) -> PartialSolution<N>
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<N: Network> Debug for PartialSolution<N>
impl<N: Network> Debug for PartialSolution<N>
source§impl<'de, N: Network> Deserialize<'de> for PartialSolution<N>
impl<'de, N: Network> Deserialize<'de> for PartialSolution<N>
source§fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
Deserializes the partial solution from a JSON-string or buffer.
source§impl<N: Network> Display for PartialSolution<N>
impl<N: Network> Display for PartialSolution<N>
source§impl<N: Network> FromBytes for PartialSolution<N>
impl<N: Network> FromBytes for PartialSolution<N>
source§impl<N: Network> FromStr for PartialSolution<N>
impl<N: Network> FromStr for PartialSolution<N>
source§impl<N: Hash + Network> Hash for PartialSolution<N>
impl<N: Hash + Network> Hash for PartialSolution<N>
source§impl<N: PartialEq + Network> PartialEq for PartialSolution<N>
impl<N: PartialEq + Network> PartialEq for PartialSolution<N>
source§fn eq(&self, other: &PartialSolution<N>) -> bool
fn eq(&self, other: &PartialSolution<N>) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl<N: Network> Serialize for PartialSolution<N>
impl<N: Network> Serialize for PartialSolution<N>
source§impl<N: Network> ToBytes for PartialSolution<N>
impl<N: Network> ToBytes for PartialSolution<N>
impl<N: Copy + Network> Copy for PartialSolution<N>
impl<N: Eq + Network> Eq for PartialSolution<N>
impl<N: Network> StructuralPartialEq for PartialSolution<N>
Auto Trait Implementations§
impl<N> RefUnwindSafe for PartialSolution<N>where
<<N as Environment>::PairingCurve as PairingEngine>::G1Affine: RefUnwindSafe,
<N as Environment>::Projective: RefUnwindSafe,
impl<N> Send for PartialSolution<N>
impl<N> Sync for PartialSolution<N>
impl<N> Unpin for PartialSolution<N>where
<<N as Environment>::PairingCurve as PairingEngine>::G1Affine: Unpin,
<N as Environment>::Projective: Unpin,
impl<N> UnwindSafe for PartialSolution<N>where
<<N as Environment>::PairingCurve as PairingEngine>::G1Affine: UnwindSafe,
<N as Environment>::Projective: 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
source§impl<'de, T> DeserializeExt<'de> for Twhere
T: DeserializeOwned,
impl<'de, T> DeserializeExt<'de> for Twhere
T: DeserializeOwned,
fn take_from_value<D>(
value: &mut Value,
field: &str
) -> Result<T, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.