Skip to main content

InputView

Trait InputView 

Source
pub trait InputView: Debug {
    // Required methods
    fn outpoint(&self) -> &OutPoint;
    fn coin(&self) -> &TxOut<Zatoshis>;

    // Provided method
    fn serialized_size(&self) -> InputSize { ... }
}
Expand description

This trait provides a minimized view of a transparent input suitable for use in fee and change computation.

Required Methods§

Source

fn outpoint(&self) -> &OutPoint

The outpoint to which the input refers.

Source

fn coin(&self) -> &TxOut<Zatoshis>

The previous output being spent.

Provided Methods§

Source

fn serialized_size(&self) -> InputSize

The size of this transparent input in a transaction, as used in ZIP 317.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl InputView for Infallible

Source§

fn outpoint(&self) -> &OutPoint

Source§

fn coin(&self) -> &TxOut<Zatoshis>

Source§

impl InputView for TransparentInputInfo<Zatoshis>

Available on crate feature transparent-inputs only.
Source§

fn outpoint(&self) -> &OutPoint

Source§

fn coin(&self) -> &TxOut<Zatoshis>

Source§

fn serialized_size(&self) -> InputSize

Implementors§