[][src]Struct bitcoin::util::psbt::Input

pub struct Input {
    pub non_witness_utxo: Option<Transaction>,
    pub witness_utxo: Option<TxOut>,
    pub partial_sigs: HashMap<PublicKey, Vec<u8>>,
    pub sighash_type: Option<SigHashType>,
    pub redeem_script: Option<Script>,
    pub witness_script: Option<Script>,
    pub hd_keypaths: HashMap<PublicKey, (Fingerprint, DerivationPath)>,
    pub final_script_sig: Option<Script>,
    pub final_script_witness: Option<Vec<Vec<u8>>>,
    pub unknown: HashMap<Key, Vec<u8>>,
}

A key-value map for an input of the corresponding index in the unsigned transaction.

Fields

non_witness_utxo: Option<Transaction>

The non-witness transaction this input spends from. Should only be std::option::Option::Some for inputs which spend non-segwit outputs or if it is unknown whether an input spends a segwit output.

witness_utxo: Option<TxOut>

The transaction output this input spends from. Should only be std::option::Option::Some for inputs which spend segwit outputs, including P2SH embedded ones.

partial_sigs: HashMap<PublicKey, Vec<u8>>

A map from public keys to their corresponding signature as would be pushed to the stack from a scriptSig or witness.

sighash_type: Option<SigHashType>

The sighash type to be used for this input. Signatures for this input must use the sighash type.

redeem_script: Option<Script>

The redeem script for this input.

witness_script: Option<Script>

The witness script for this input.

hd_keypaths: HashMap<PublicKey, (Fingerprint, DerivationPath)>

A map from public keys needed to sign this input to their corresponding master key fingerprints and derivation paths.

final_script_sig: Option<Script>

The finalized, fully-constructed scriptSig with signatures and any other scripts necessary for this input to pass validation.

final_script_witness: Option<Vec<Vec<u8>>>

The finalized, fully-constructed scriptWitness with signatures and any other scripts necessary for this input to pass validation.

unknown: HashMap<Key, Vec<u8>>

Unknown key-value pairs for this input.

Trait Implementations

impl Map for Input[src]

impl<S: Encoder> Encodable<S> for Input[src]

impl<D: Decoder> Decodable<D> for Input[src]

impl PartialEq<Input> for Input[src]

impl Default for Input[src]

impl Clone for Input[src]

fn clone_from(&mut self, source: &Self)
1.0.0
[src]

Performs copy-assignment from source. Read more

impl Debug for Input[src]

Auto Trait Implementations

impl Send for Input

impl Sync for Input

Blanket Implementations

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

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

type Owned = T

impl<T> From for T[src]

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

type Error = Infallible

The type returned in the event of a conversion error.

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

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

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

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

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

The type returned in the event of a conversion error.