Struct snarkvm_dpc::base_dpc::transaction::DPCTransaction [−][src]
Fields
network: Network
The network this transaction is included in
ledger_digest: MerkleTreeDigest<C::MerkleParameters>
The root of the ledger commitment Merkle tree
old_serial_numbers: Vec<<C::AccountSignature as SignatureScheme>::PublicKey>
The serial numbers of the records being spend
new_commitments: Vec<<C::RecordCommitment as CommitmentScheme>::Output>
The commitment of the new records
program_commitment: <C::ProgramVerificationKeyCommitment as CommitmentScheme>::Output
The commitment to the old record death and new record birth programs
local_data_root: <C::LocalDataCRH as CRH>::Output
The root of the local data merkle tree
value_balance: AleoAmount
A transaction value balance is the difference between input and output record balances. This value effectively becomes the transaction fee for the miner. Only coinbase transactions can have a negative value balance representing tokens being minted.
signatures: Vec<<C::AccountSignature as SignatureScheme>::Output>
Randomized signatures that allow for authorized delegation of transaction generation
encrypted_records: Vec<EncryptedRecord<C>>
Encrypted record and selector bits of the new records generated by the transaction
transaction_proof: <C::OuterSNARK as SNARK>::Proof
Zero-knowledge proof attesting to the valididty of the transaction
memorandum: [u8; 32]
Public data associated with the transaction that must be unique among all transactions
inner_circuit_id: <C::InnerSNARKVerificationKeyCRH as CRH>::Output
The ID of the inner SNARK being used
Implementations
impl<C: BaseDPCComponents> DPCTransaction<C>
[src]
pub fn new(
old_serial_numbers: Vec<Self::SerialNumber>,
new_commitments: Vec<Self::Commitment>,
memorandum: Self::Memorandum,
ledger_digest: MerkleTreeDigest<C::MerkleParameters>,
inner_circuit_id: <C::InnerSNARKVerificationKeyCRH as CRH>::Output,
transaction_proof: <C::OuterSNARK as SNARK>::Proof,
program_commitment: <C::ProgramVerificationKeyCommitment as CommitmentScheme>::Output,
local_data_root: <C::LocalDataCRH as CRH>::Output,
value_balance: AleoAmount,
network: Network,
signatures: Vec<<C::AccountSignature as SignatureScheme>::Output>,
encrypted_records: Vec<EncryptedRecord<C>>
) -> Self
[src]
old_serial_numbers: Vec<Self::SerialNumber>,
new_commitments: Vec<Self::Commitment>,
memorandum: Self::Memorandum,
ledger_digest: MerkleTreeDigest<C::MerkleParameters>,
inner_circuit_id: <C::InnerSNARKVerificationKeyCRH as CRH>::Output,
transaction_proof: <C::OuterSNARK as SNARK>::Proof,
program_commitment: <C::ProgramVerificationKeyCommitment as CommitmentScheme>::Output,
local_data_root: <C::LocalDataCRH as CRH>::Output,
value_balance: AleoAmount,
network: Network,
signatures: Vec<<C::AccountSignature as SignatureScheme>::Output>,
encrypted_records: Vec<EncryptedRecord<C>>
) -> Self
Trait Implementations
impl<C: BaseDPCComponents> Clone for DPCTransaction<C> where
C: BaseDPCComponents,
[src]
C: BaseDPCComponents,
fn clone(&self) -> Self
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl<C: BaseDPCComponents> Debug for DPCTransaction<C>
[src]
impl<C: BaseDPCComponents> Eq for DPCTransaction<C> where
C: BaseDPCComponents,
[src]
C: BaseDPCComponents,
impl<C: BaseDPCComponents> FromBytes for DPCTransaction<C>
[src]
impl<C: BaseDPCComponents> PartialEq<DPCTransaction<C>> for DPCTransaction<C> where
C: BaseDPCComponents,
[src]
C: BaseDPCComponents,
impl<C: BaseDPCComponents> ToBytes for DPCTransaction<C>
[src]
impl<C: BaseDPCComponents> Transaction for DPCTransaction<C>
[src]
type Commitment = <C::RecordCommitment as CommitmentScheme>::Output
type Digest = MerkleTreeDigest<C::MerkleParameters>
type EncryptedRecord = EncryptedRecord<C>
type InnerSNARKID = <C::InnerSNARKVerificationKeyCRH as CRH>::Output
type LocalDataRoot = <C::LocalDataCRH as CRH>::Output
type Memorandum = [u8; 32]
type ProgramCommitment = <C::ProgramVerificationKeyCommitment as CommitmentScheme>::Output
type SerialNumber = <C::AccountSignature as SignatureScheme>::PublicKey
type ValueBalance = AleoAmount
fn transaction_id(&self) -> Result<[u8; 32], TransactionError>
[src]
Transaction id = Hash of (serial numbers || commitments || memo)
fn network_id(&self) -> u8
[src]
fn ledger_digest(&self) -> &Self::Digest
[src]
fn inner_circuit_id(&self) -> &Self::InnerSNARKID
[src]
fn old_serial_numbers(&self) -> &[Self::SerialNumber]
[src]
fn new_commitments(&self) -> &[Self::Commitment]
[src]
fn program_commitment(&self) -> &Self::ProgramCommitment
[src]
fn local_data_root(&self) -> &Self::LocalDataRoot
[src]
fn value_balance(&self) -> Self::ValueBalance
[src]
fn encrypted_records(&self) -> &[Self::EncryptedRecord]
[src]
fn memorandum(&self) -> &Self::Memorandum
[src]
fn size(&self) -> usize
[src]
Auto Trait Implementations
impl<C> RefUnwindSafe for DPCTransaction<C> where
<<C as DPCComponents>::AccountSignature as SignatureScheme>::Output: RefUnwindSafe,
<<<C as BaseDPCComponents>::MerkleParameters as MerkleParameters>::H as CRH>::Output: RefUnwindSafe,
<<C as DPCComponents>::InnerSNARKVerificationKeyCRH as CRH>::Output: RefUnwindSafe,
<<C as DPCComponents>::LocalDataCRH as CRH>::Output: RefUnwindSafe,
<<C as DPCComponents>::ProgramVerificationKeyCommitment as CommitmentScheme>::Output: RefUnwindSafe,
<<C as DPCComponents>::RecordCommitment as CommitmentScheme>::Output: RefUnwindSafe,
<<C as BaseDPCComponents>::OuterSNARK as SNARK>::Proof: RefUnwindSafe,
<<C as DPCComponents>::AccountSignature as SignatureScheme>::PublicKey: RefUnwindSafe,
<<C as DPCComponents>::AccountEncryption as EncryptionScheme>::Text: RefUnwindSafe,
<<C as DPCComponents>::AccountSignature as SignatureScheme>::Output: RefUnwindSafe,
<<<C as BaseDPCComponents>::MerkleParameters as MerkleParameters>::H as CRH>::Output: RefUnwindSafe,
<<C as DPCComponents>::InnerSNARKVerificationKeyCRH as CRH>::Output: RefUnwindSafe,
<<C as DPCComponents>::LocalDataCRH as CRH>::Output: RefUnwindSafe,
<<C as DPCComponents>::ProgramVerificationKeyCommitment as CommitmentScheme>::Output: RefUnwindSafe,
<<C as DPCComponents>::RecordCommitment as CommitmentScheme>::Output: RefUnwindSafe,
<<C as BaseDPCComponents>::OuterSNARK as SNARK>::Proof: RefUnwindSafe,
<<C as DPCComponents>::AccountSignature as SignatureScheme>::PublicKey: RefUnwindSafe,
<<C as DPCComponents>::AccountEncryption as EncryptionScheme>::Text: RefUnwindSafe,
impl<C> Send for DPCTransaction<C> where
<<<C as BaseDPCComponents>::MerkleParameters as MerkleParameters>::H as CRH>::Output: Send,
<<C as DPCComponents>::InnerSNARKVerificationKeyCRH as CRH>::Output: Send,
<<C as DPCComponents>::LocalDataCRH as CRH>::Output: Send,
<<C as DPCComponents>::ProgramVerificationKeyCommitment as CommitmentScheme>::Output: Send,
<<C as DPCComponents>::RecordCommitment as CommitmentScheme>::Output: Send,
<<C as BaseDPCComponents>::OuterSNARK as SNARK>::Proof: Send,
<<C as DPCComponents>::AccountEncryption as EncryptionScheme>::Text: Send,
<<<C as BaseDPCComponents>::MerkleParameters as MerkleParameters>::H as CRH>::Output: Send,
<<C as DPCComponents>::InnerSNARKVerificationKeyCRH as CRH>::Output: Send,
<<C as DPCComponents>::LocalDataCRH as CRH>::Output: Send,
<<C as DPCComponents>::ProgramVerificationKeyCommitment as CommitmentScheme>::Output: Send,
<<C as DPCComponents>::RecordCommitment as CommitmentScheme>::Output: Send,
<<C as BaseDPCComponents>::OuterSNARK as SNARK>::Proof: Send,
<<C as DPCComponents>::AccountEncryption as EncryptionScheme>::Text: Send,
impl<C> Sync for DPCTransaction<C> where
<<<C as BaseDPCComponents>::MerkleParameters as MerkleParameters>::H as CRH>::Output: Sync,
<<C as DPCComponents>::InnerSNARKVerificationKeyCRH as CRH>::Output: Sync,
<<C as DPCComponents>::LocalDataCRH as CRH>::Output: Sync,
<<C as DPCComponents>::ProgramVerificationKeyCommitment as CommitmentScheme>::Output: Sync,
<<C as DPCComponents>::RecordCommitment as CommitmentScheme>::Output: Sync,
<<C as BaseDPCComponents>::OuterSNARK as SNARK>::Proof: Sync,
<<C as DPCComponents>::AccountEncryption as EncryptionScheme>::Text: Sync,
<<<C as BaseDPCComponents>::MerkleParameters as MerkleParameters>::H as CRH>::Output: Sync,
<<C as DPCComponents>::InnerSNARKVerificationKeyCRH as CRH>::Output: Sync,
<<C as DPCComponents>::LocalDataCRH as CRH>::Output: Sync,
<<C as DPCComponents>::ProgramVerificationKeyCommitment as CommitmentScheme>::Output: Sync,
<<C as DPCComponents>::RecordCommitment as CommitmentScheme>::Output: Sync,
<<C as BaseDPCComponents>::OuterSNARK as SNARK>::Proof: Sync,
<<C as DPCComponents>::AccountEncryption as EncryptionScheme>::Text: Sync,
impl<C> Unpin for DPCTransaction<C> where
<<C as DPCComponents>::AccountSignature as SignatureScheme>::Output: Unpin,
<<<C as BaseDPCComponents>::MerkleParameters as MerkleParameters>::H as CRH>::Output: Unpin,
<<C as DPCComponents>::InnerSNARKVerificationKeyCRH as CRH>::Output: Unpin,
<<C as DPCComponents>::LocalDataCRH as CRH>::Output: Unpin,
<<C as DPCComponents>::ProgramVerificationKeyCommitment as CommitmentScheme>::Output: Unpin,
<<C as DPCComponents>::RecordCommitment as CommitmentScheme>::Output: Unpin,
<<C as BaseDPCComponents>::OuterSNARK as SNARK>::Proof: Unpin,
<<C as DPCComponents>::AccountSignature as SignatureScheme>::PublicKey: Unpin,
<<C as DPCComponents>::AccountEncryption as EncryptionScheme>::Text: Unpin,
<<C as DPCComponents>::AccountSignature as SignatureScheme>::Output: Unpin,
<<<C as BaseDPCComponents>::MerkleParameters as MerkleParameters>::H as CRH>::Output: Unpin,
<<C as DPCComponents>::InnerSNARKVerificationKeyCRH as CRH>::Output: Unpin,
<<C as DPCComponents>::LocalDataCRH as CRH>::Output: Unpin,
<<C as DPCComponents>::ProgramVerificationKeyCommitment as CommitmentScheme>::Output: Unpin,
<<C as DPCComponents>::RecordCommitment as CommitmentScheme>::Output: Unpin,
<<C as BaseDPCComponents>::OuterSNARK as SNARK>::Proof: Unpin,
<<C as DPCComponents>::AccountSignature as SignatureScheme>::PublicKey: Unpin,
<<C as DPCComponents>::AccountEncryption as EncryptionScheme>::Text: Unpin,
impl<C> UnwindSafe for DPCTransaction<C> where
<<C as DPCComponents>::AccountSignature as SignatureScheme>::Output: UnwindSafe,
<<<C as BaseDPCComponents>::MerkleParameters as MerkleParameters>::H as CRH>::Output: UnwindSafe,
<<C as DPCComponents>::InnerSNARKVerificationKeyCRH as CRH>::Output: UnwindSafe,
<<C as DPCComponents>::LocalDataCRH as CRH>::Output: UnwindSafe,
<<C as DPCComponents>::ProgramVerificationKeyCommitment as CommitmentScheme>::Output: UnwindSafe,
<<C as DPCComponents>::RecordCommitment as CommitmentScheme>::Output: UnwindSafe,
<<C as BaseDPCComponents>::OuterSNARK as SNARK>::Proof: UnwindSafe,
<<C as DPCComponents>::AccountSignature as SignatureScheme>::PublicKey: UnwindSafe,
<<C as DPCComponents>::AccountEncryption as EncryptionScheme>::Text: UnwindSafe,
<<C as DPCComponents>::AccountSignature as SignatureScheme>::Output: UnwindSafe,
<<<C as BaseDPCComponents>::MerkleParameters as MerkleParameters>::H as CRH>::Output: UnwindSafe,
<<C as DPCComponents>::InnerSNARKVerificationKeyCRH as CRH>::Output: UnwindSafe,
<<C as DPCComponents>::LocalDataCRH as CRH>::Output: UnwindSafe,
<<C as DPCComponents>::ProgramVerificationKeyCommitment as CommitmentScheme>::Output: UnwindSafe,
<<C as DPCComponents>::RecordCommitment as CommitmentScheme>::Output: UnwindSafe,
<<C as BaseDPCComponents>::OuterSNARK as SNARK>::Proof: UnwindSafe,
<<C as DPCComponents>::AccountSignature as SignatureScheme>::PublicKey: UnwindSafe,
<<C as DPCComponents>::AccountEncryption as EncryptionScheme>::Text: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<Q, K> Equivalent<K> for Q where
K: Borrow<Q> + ?Sized,
Q: Eq + ?Sized,
[src]
K: Borrow<Q> + ?Sized,
Q: Eq + ?Sized,
pub fn equivalent(&self, key: &K) -> bool
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Pointable for T
pub const ALIGN: usize
type Init = T
The type for initializers.
pub unsafe fn init(init: <T as Pointable>::Init) -> usize
pub unsafe fn deref<'a>(ptr: usize) -> &'a T
pub unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T
pub unsafe fn drop(ptr: usize)
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,