pub struct PartiallySignedTransaction {
pub unsigned_tx: Transaction,
pub version: u32,
pub xpub: BTreeMap<ExtendedPubKey, KeySource>,
pub proprietary: BTreeMap<ProprietaryKey, Vec<u8>>,
pub unknown: BTreeMap<Key, Vec<u8>>,
pub inputs: Vec<Input>,
pub outputs: Vec<Output>,
}
Expand description
A Partially Signed Transaction.
Fields
unsigned_tx: Transaction
The unsigned transaction, scriptSigs and witnesses for each input must be empty.
version: u32
The version number of this PSBT. If omitted, the version number is 0.
xpub: BTreeMap<ExtendedPubKey, KeySource>
A global map from extended public keys to the used key fingerprint and derivation path as defined by BIP 32
proprietary: BTreeMap<ProprietaryKey, Vec<u8>>
Global proprietary key-value pairs.
unknown: BTreeMap<Key, Vec<u8>>
Unknown global key-value pairs.
inputs: Vec<Input>
The corresponding key-value map for each input in the unsigned transaction.
outputs: Vec<Output>
The corresponding key-value map for each output in the unsigned transaction.
Implementations
sourceimpl PartiallySignedTransaction
impl PartiallySignedTransaction
sourcepub fn from_unsigned_tx(tx: Transaction) -> Result<Self, Error>
pub fn from_unsigned_tx(tx: Transaction) -> Result<Self, Error>
Create a PartiallySignedTransaction from an unsigned transaction, error if not unsigned
sourcepub fn extract_tx(self) -> Transaction
pub fn extract_tx(self) -> Transaction
Extract the Transaction from a PartiallySignedTransaction by filling in the available signature information in place.
Trait Implementations
sourceimpl Clone for PartiallySignedTransaction
impl Clone for PartiallySignedTransaction
sourcefn clone(&self) -> PartiallySignedTransaction
fn clone(&self) -> PartiallySignedTransaction
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for PartiallySignedTransaction
impl Debug for PartiallySignedTransaction
sourceimpl Decodable for PartiallySignedTransaction
impl Decodable for PartiallySignedTransaction
sourcefn consensus_decode<D: Read>(d: D) -> Result<Self, Error>
fn consensus_decode<D: Read>(d: D) -> Result<Self, Error>
Decode an object with a well-defined format
sourceimpl<'de> Deserialize<'de> for PartiallySignedTransaction
impl<'de> Deserialize<'de> for PartiallySignedTransaction
sourcefn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
sourceimpl Display for PartiallySignedTransaction
Available on crate feature base64
only.
impl Display for PartiallySignedTransaction
base64
only.sourceimpl FromStr for PartiallySignedTransaction
Available on crate feature base64
only.
impl FromStr for PartiallySignedTransaction
base64
only.sourceimpl PartialEq<PartiallySignedTransaction> for PartiallySignedTransaction
impl PartialEq<PartiallySignedTransaction> for PartiallySignedTransaction
sourcefn eq(&self, other: &PartiallySignedTransaction) -> bool
fn eq(&self, other: &PartiallySignedTransaction) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &PartiallySignedTransaction) -> bool
fn ne(&self, other: &PartiallySignedTransaction) -> bool
This method tests for !=
.
impl Eq for PartiallySignedTransaction
impl StructuralEq for PartiallySignedTransaction
impl StructuralPartialEq for PartiallySignedTransaction
Auto Trait Implementations
impl RefUnwindSafe for PartiallySignedTransaction
impl Send for PartiallySignedTransaction
impl Sync for PartiallySignedTransaction
impl Unpin for PartiallySignedTransaction
impl UnwindSafe for PartiallySignedTransaction
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
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.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more