Struct monero::blockdata::transaction::TransactionPrefix [−][src]
pub struct TransactionPrefix { pub version: VarInt, pub unlock_time: VarInt, pub inputs: Vec<TxIn>, pub outputs: Vec<TxOut>, pub extra: ExtraField, }
Expand description
The part of the transaction that contains all the data except signatures.
As transaction prefix implements hash::Hashable
it is possible to generate the transaction
prefix hash with tx_prefix.hash()
.
Fields
version: VarInt
Transaction format version.
unlock_time: VarInt
The transaction can not be spend until after a certain number of blocks, or until a certain time.
inputs: Vec<TxIn>
Array of inputs.
outputs: Vec<TxOut>
Array of outputs.
extra: ExtraField
Additional data associated with a transaction.
Implementations
impl TransactionPrefix
[src]
impl TransactionPrefix
[src]pub fn nb_outputs(&self) -> usize
[src]
pub fn nb_outputs(&self) -> usize
[src]Return the number of transaction’s outputs.
pub fn tx_pubkey(&self) -> Option<PublicKey>
[src]
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]
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>,
rct_sig_base: Option<&RctSigBase>
) -> Result<Vec<OwnedTxOut<'_>>, Error>
[src]
pub fn check_outputs(
&self,
pair: &ViewPair,
major: Range<u32>,
minor: Range<u32>,
rct_sig_base: Option<&RctSigBase>
) -> Result<Vec<OwnedTxOut<'_>>, Error>
[src]Iterate over transaction outputs and find outputs related to view pair.
Trait Implementations
impl Clone for TransactionPrefix
[src]
impl Clone for TransactionPrefix
[src]fn clone(&self) -> TransactionPrefix
[src]
fn clone(&self) -> TransactionPrefix
[src]Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]Performs copy-assignment from source
. Read more
impl Debug for TransactionPrefix
[src]
impl Debug for TransactionPrefix
[src]impl Decodable for TransactionPrefix
[src]
impl Decodable for TransactionPrefix
[src]fn consensus_decode<D: Read>(d: &mut D) -> Result<TransactionPrefix, Error>
[src]
fn consensus_decode<D: Read>(d: &mut D) -> Result<TransactionPrefix, Error>
[src]Decode an object with a well-defined format.
impl Default for TransactionPrefix
[src]
impl Default for TransactionPrefix
[src]fn default() -> TransactionPrefix
[src]
fn default() -> TransactionPrefix
[src]Returns the “default value” for a type. Read more
impl<'de> Deserialize<'de> for TransactionPrefix
[src]
impl<'de> Deserialize<'de> for TransactionPrefix
[src]fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]Deserialize this value from the given Serde deserializer. Read more
impl Display for TransactionPrefix
[src]
impl Display for TransactionPrefix
[src]impl Encodable for TransactionPrefix
[src]
impl Encodable for TransactionPrefix
[src]impl Hashable for TransactionPrefix
[src]
impl Hashable for TransactionPrefix
[src]fn hash_to_scalar(&self) -> PrivateKey
[src]
fn hash_to_scalar(&self) -> PrivateKey
[src]impl Serialize for TransactionPrefix
[src]
impl Serialize for TransactionPrefix
[src]impl StrictDecode for TransactionPrefix
[src]
impl StrictDecode for TransactionPrefix
[src]strict_encoding_support
only.impl StrictEncode for TransactionPrefix
[src]
impl StrictEncode for TransactionPrefix
[src]strict_encoding_support
only.Auto Trait Implementations
impl RefUnwindSafe for TransactionPrefix
impl Send for TransactionPrefix
impl Sync for TransactionPrefix
impl Unpin for TransactionPrefix
impl UnwindSafe for TransactionPrefix
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> Same<T> for T
impl<T> Same<T> for T
type Output = T
type Output = T
Should always be Self
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more
impl<T> DeserializeOwned for T where
T: for<'de> Deserialize<'de>,
[src]
T: for<'de> Deserialize<'de>,