pub struct TransactionBuilder {
    pub transaction: Transaction,
    pub utxos: Vec<UtxoEntry>,
    pub used_utxos: Vec<UtxoEntry>,
}

Fields§

§transaction: Transaction§utxos: Vec<UtxoEntry>§used_utxos: Vec<UtxoEntry>

Implementations§

source§

impl TransactionBuilder

source

pub fn with_options_height(&mut self, height: i64) -> &mut Self

source

pub fn with_input(&mut self, input: &Input) -> &mut Self

source

pub fn with_observation( &mut self, o: &Observation, height: i64, address: &Address ) -> &mut Self

source

pub fn with_no_salt(&mut self) -> &mut Self

source

pub fn with_time(&mut self, time: Option<i64>) -> &mut Self

source

pub fn with_fee( &mut self, destination: &Address, amount: &CurrencyAmount ) -> RgResult<&mut Self>

source

pub fn with_utxo( &mut self, utxo_entry: &UtxoEntry ) -> Result<&mut Self, ErrorInfo>

source

pub fn with_maybe_currency_utxo( &mut self, utxo_entry: &UtxoEntry ) -> Result<&mut Self, ErrorInfo>

source

pub fn with_message( &mut self, msg: impl Into<String> ) -> Result<&mut Self, ErrorInfo>

source

pub fn with_address_info( &mut self, ai: AddressInfo ) -> Result<&mut Self, ErrorInfo>

source

pub fn with_output( &mut self, destination: &Address, amount: &CurrencyAmount ) -> &mut Self

source

pub fn with_contract_request_output( &mut self, destination: &Address, serialized_request: &Vec<u8> ) -> RgResult<&mut Self>

source

pub fn with_contract_deploy_output_and_predicate_input( &mut self, code: impl AsRef<[u8]>, c_amount: CurrencyAmount, use_predicate_input: bool ) -> RgResult<&mut Self>

source

pub fn with_last_output_deposit_swap(&mut self, btc_txid: String) -> &mut Self

source

pub fn with_unsigned_input( &mut self, utxo: UtxoEntry ) -> Result<&mut Self, ErrorInfo>

source

pub fn balance(&self) -> i64

source

pub fn build(&mut self) -> Result<Transaction, ErrorInfo>

source

pub fn with_output_peer_data( &mut self, destination: &Address, pd: PeerMetadata, height: i64 ) -> &mut Self

source

pub fn genesis_peer_data(&mut self) -> &mut Self

source

pub fn with_output_node_metadata( &mut self, destination: &Address, pd: NodeMetadata, height: i64 ) -> &mut Self

source

pub fn with_genesis_input(&mut self, address: &Address) -> &mut Self

source

pub fn with_remainder(&mut self) -> &mut Self

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for Twhere U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> Same for T

§

type Output = T

Should always be Self
source§

impl<T, U> TryFrom<U> for Twhere U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for Twhere U: TryFrom<T>,

§

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

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.