Struct monero::blockdata::transaction::Transaction[][src]

pub struct Transaction {
    pub prefix: TransactionPrefix,
    pub signatures: Vec<Vec<Signature>>,
    pub rct_signatures: RctSig,
}

A full transaction containing the prefix and all the signing data.

As transaction implements hash::Hashable it is possible to generate the transaction hash with tx.hash().

Fields

prefix: TransactionPrefix

The transaction prefix.

signatures: Vec<Vec<Signature>>

The signatures.

rct_signatures: RctSig

The RingCT signatures.

Implementations

impl Transaction[src]

pub fn prefix(&self) -> &TransactionPrefix[src]

Return the transaction prefix.

pub fn nb_inputs(&self) -> usize[src]

Return the number of transaction’s inputs.

pub fn nb_outputs(&self) -> usize[src]

Return the number of transaction’s outputs.

pub fn tx_pubkey(&self) -> Option<PublicKey>[src]

Return the transaction public key present in extra field.

pub fn tx_additional_pubkeys(&self) -> Option<Vec<PublicKey>>[src]

Return the additional public keys present in extra field.

pub fn check_outputs(
    &self,
    pair: &ViewPair,
    major: Range<u32>,
    minor: Range<u32>
) -> Result<Vec<OwnedTxOut<'_>>, Error>
[src]

Iterate over transaction outputs and find outputs related to view pair.

pub fn get_amount<'a>(
    &self,
    view_pair: &ViewPair,
    out: &OwnedTxOut<'_>
) -> Result<u64, RecoveryError>
[src]

Calculate an output’s amount.

Trait Implementations

impl Clone for Transaction[src]

impl Debug for Transaction[src]

impl Decodable for Transaction[src]

impl Default for Transaction[src]

impl<'de> Deserialize<'de> for Transaction[src]

impl Display for Transaction[src]

impl Encodable for Transaction[src]

impl Hashable for Transaction[src]

impl Serialize for Transaction[src]

impl StrictDecode for Transaction[src]

This is supported on crate feature strict_encoding_support only.

impl StrictEncode for Transaction[src]

This is supported on crate feature strict_encoding_support only.

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.