pub struct PartialInput {
pub witness_txid: Txid,
pub witness_output_index: u32,
pub witness_utxo: TxOut,
pub sequence: Sequence,
pub locktime: LockTime,
pub amount: Option<u64>,
pub asset: Option<AssetId>,
pub secrets: Option<TxOutSecrets>,
}Expand description
Represents partially prepared input data for Elements transactions.
Fields§
§witness_txid: TxidThe transaction ID containing the target UTXO being spent.
witness_output_index: u32The output index of the UTXO within the transaction being spent.
witness_utxo: TxOutThe native transaction output corresponding to the targeted UTXO.
sequence: SequenceThe sequence number indicating transaction replaceability or relative timelocking.
locktime: LockTimeAbsolute timelock criteria enforced against the input.
amount: Option<u64>The explicit amount value in Satoshis for the input, if available.
Note: if UTXO is explicit, amount and asset are Some.
asset: Option<AssetId>The explicit AssetId being spent by the input, if available.
secrets: Option<TxOutSecrets>Optional blinding secrets mapping values and asset states into confidential outputs.
Note: if UTXO is confidential, secrets are Some.
Implementations§
Source§impl PartialInput
impl PartialInput
Sourcepub fn new(utxo: UTXO) -> PartialInput
pub fn new(utxo: UTXO) -> PartialInput
Creates a new PartialInput from an existing UTXO.
Extracts explicit value and asset amounts if available.
Sourcepub fn with_sequence(self, sequence: Sequence) -> PartialInput
pub fn with_sequence(self, sequence: Sequence) -> PartialInput
Sets a specific Sequence for the input.
Sourcepub fn with_locktime(self, locktime: LockTime) -> PartialInput
pub fn with_locktime(self, locktime: LockTime) -> PartialInput
Sets a specific LockTime for the input.
Trait Implementations§
Source§impl Clone for PartialInput
impl Clone for PartialInput
Source§fn clone(&self) -> PartialInput
fn clone(&self) -> PartialInput
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl Freeze for PartialInput
impl RefUnwindSafe for PartialInput
impl Send for PartialInput
impl Sync for PartialInput
impl Unpin for PartialInput
impl UnsafeUnpin for PartialInput
impl UnwindSafe for PartialInput
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more