Struct snarkvm_dpc::record::record_proof::RecordProof
source · [−]pub struct RecordProof<N: Network> { /* private fields */ }
Expand description
A proof of inclusion for a record in a block.
Implementations
sourceimpl<N: Network> RecordProof<N>
impl<N: Network> RecordProof<N>
sourcepub fn new_dummy(local_proof: LocalProof<N>) -> Result<Self>
pub fn new_dummy(local_proof: LocalProof<N>) -> Result<Self>
Initializes a new dummy instance of RecordProof
.
sourcepub fn new(
block_hash: N::BlockHash,
previous_block_hash: N::BlockHash,
block_header_root: N::BlockHeaderRoot,
block_header_inclusion_proof: MerklePath<N::BlockHeaderRootParameters>,
transactions_root: N::TransactionsRoot,
transactions_inclusion_proof: MerklePath<N::TransactionsRootParameters>,
local_proof: LocalProof<N>
) -> Result<Self>
pub fn new(
block_hash: N::BlockHash,
previous_block_hash: N::BlockHash,
block_header_root: N::BlockHeaderRoot,
block_header_inclusion_proof: MerklePath<N::BlockHeaderRootParameters>,
transactions_root: N::TransactionsRoot,
transactions_inclusion_proof: MerklePath<N::TransactionsRootParameters>,
local_proof: LocalProof<N>
) -> Result<Self>
Initializes a new instance of RecordProof
.
sourcepub fn block_hash(&self) -> N::BlockHash
pub fn block_hash(&self) -> N::BlockHash
Returns the block hash.
sourcepub fn previous_block_hash(&self) -> N::BlockHash
pub fn previous_block_hash(&self) -> N::BlockHash
Returns the previous block hash.
sourcepub fn block_header_root(&self) -> N::BlockHeaderRoot
pub fn block_header_root(&self) -> N::BlockHeaderRoot
Returns the block header root.
sourcepub fn block_header_inclusion_proof(
&self
) -> &MerklePath<N::BlockHeaderRootParameters>
pub fn block_header_inclusion_proof(
&self
) -> &MerklePath<N::BlockHeaderRootParameters>
Returns the block header inclusion proof.
sourcepub fn transactions_root(&self) -> N::TransactionsRoot
pub fn transactions_root(&self) -> N::TransactionsRoot
Returns the transactions root.
sourcepub fn transactions_inclusion_proof(
&self
) -> &MerklePath<N::TransactionsRootParameters>
pub fn transactions_inclusion_proof(
&self
) -> &MerklePath<N::TransactionsRootParameters>
Returns the transactions inclusion proof.
sourcepub fn transaction_id(&self) -> N::TransactionID
pub fn transaction_id(&self) -> N::TransactionID
Returns the transaction ID.
sourcepub fn transaction_inclusion_proof(
&self
) -> &MerklePath<N::TransactionIDParameters>
pub fn transaction_inclusion_proof(
&self
) -> &MerklePath<N::TransactionIDParameters>
Returns the transaction inclusion proof.
sourcepub fn transition_id(&self) -> N::TransitionID
pub fn transition_id(&self) -> N::TransitionID
Returns the transition ID.
sourcepub fn transition_inclusion_proof(
&self
) -> &MerklePath<N::TransitionIDParameters>
pub fn transition_inclusion_proof(
&self
) -> &MerklePath<N::TransitionIDParameters>
Returns the transition inclusion proof.
sourcepub fn commitment(&self) -> N::Commitment
pub fn commitment(&self) -> N::Commitment
Returns the commitment.
sourcepub fn local_proof(&self) -> &LocalProof<N>
pub fn local_proof(&self) -> &LocalProof<N>
Returns the local proof.
Trait Implementations
sourceimpl<N: Network> Clone for RecordProof<N> where
N: Network,
impl<N: Network> Clone for RecordProof<N> where
N: Network,
sourceimpl<N: Network> Debug for RecordProof<N> where
N: Network,
impl<N: Network> Debug for RecordProof<N> where
N: Network,
sourceimpl<N: Network> Default for RecordProof<N>
impl<N: Network> Default for RecordProof<N>
sourceimpl<N: Network> FromBytes for RecordProof<N>
impl<N: Network> FromBytes for RecordProof<N>
Auto Trait Implementations
impl<N> RefUnwindSafe for RecordProof<N> where
<N as Network>::BlockHash: RefUnwindSafe,
<N as Network>::BlockHeaderRoot: RefUnwindSafe,
<N as Network>::BlockHeaderRootParameters: RefUnwindSafe,
<N as Network>::Commitment: RefUnwindSafe,
<N as Network>::InnerScalarField: RefUnwindSafe,
<N as Network>::TransactionID: RefUnwindSafe,
<N as Network>::TransactionIDParameters: RefUnwindSafe,
<N as Network>::TransactionsRoot: RefUnwindSafe,
<N as Network>::TransactionsRootParameters: RefUnwindSafe,
<N as Network>::TransitionID: RefUnwindSafe,
<N as Network>::TransitionIDParameters: RefUnwindSafe,
impl<N> Send for RecordProof<N>
impl<N> Sync for RecordProof<N>
impl<N> Unpin for RecordProof<N> where
<N as Network>::BlockHash: Unpin,
<N as Network>::BlockHeaderRoot: Unpin,
<N as Network>::Commitment: Unpin,
<N as Network>::InnerScalarField: Unpin,
<N as Network>::TransactionID: Unpin,
<N as Network>::TransactionsRoot: Unpin,
<N as Network>::TransitionID: Unpin,
impl<N> UnwindSafe for RecordProof<N> where
<N as Network>::BlockHash: UnwindSafe,
<N as Network>::BlockHeaderRoot: UnwindSafe,
<N as Network>::BlockHeaderRootParameters: RefUnwindSafe,
<N as Network>::Commitment: UnwindSafe,
<N as Network>::InnerScalarField: UnwindSafe,
<N as Network>::TransactionID: UnwindSafe,
<N as Network>::TransactionIDParameters: RefUnwindSafe,
<N as Network>::TransactionsRoot: UnwindSafe,
<N as Network>::TransactionsRootParameters: RefUnwindSafe,
<N as Network>::TransitionID: UnwindSafe,
<N as Network>::TransitionIDParameters: RefUnwindSafe,
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