[][src]Struct miniscript::miniscript::types::extra_props::ExtData

pub struct ExtData {
    pub pk_cost: usize,
    pub has_free_verify: bool,
    pub ops_count_static: usize,
    pub ops_count_sat: Option<usize>,
    pub ops_count_nsat: Option<usize>,
    pub stack_elem_count_sat: Option<usize>,
    pub stack_elem_count_dissat: Option<usize>,
    pub max_sat_size: Option<(usize, usize)>,
    pub max_dissat_size: Option<(usize, usize)>,
    pub timelock_info: TimeLockInfo,
}

Structure representing the extra type properties of a fragment.

Fields

pk_cost: usize

The number of bytes needed to encode its scriptpubkey

has_free_verify: bool

Whether this fragment can be verify-wrapped for free

ops_count_static: usize

The worst case static(unexecuted) ops-count for this Miniscript fragment.

ops_count_sat: Option<usize>

The worst case ops-count for satisfying this Miniscript fragment.

ops_count_nsat: Option<usize>

The worst case ops-count for dissatisfying this Miniscript fragment.

stack_elem_count_sat: Option<usize>

The worst case number of stack elements for satisfying this Miniscript fragment.

stack_elem_count_dissat: Option<usize>

The worst case number of stack elements for dissatisfying this Miniscript fragment.

max_sat_size: Option<(usize, usize)>

Maximum size, in bytes, of a satisfying witness. First elements is the cost for the witness stack, the second one is the cost for scriptSig. All signatures are assumed to be 73 bytes in size, including the length prefix (segwit) or push opcode (pre-segwit) and sighash postfix.

max_dissat_size: Option<(usize, usize)>

Maximum dissatisfaction cost, in bytes, of a Miniscript fragment. First elements is the cost for the witness stack, the second one is the cost for scriptSig.

timelock_info: TimeLockInfo

The timelock info about heightlocks and timelocks

Trait Implementations

impl Clone for ExtData[src]

impl Copy for ExtData[src]

impl Debug for ExtData[src]

impl Eq for ExtData[src]

impl Hash for ExtData[src]

impl Ord for ExtData[src]

impl PartialEq<ExtData> for ExtData[src]

impl PartialOrd<ExtData> for ExtData[src]

impl Property for ExtData[src]

fn type_check<Pk, Ctx, C>(
    fragment: &Terminal<Pk, Ctx>,
    _child: C
) -> Result<Self, Error<Pk, Ctx>> where
    C: FnMut(usize) -> Option<Self>,
    Ctx: ScriptContext,
    Pk: MiniscriptKey
[src]

Compute the type of a fragment assuming all the children of Miniscript have been computed already.

impl StructuralEq for ExtData[src]

impl StructuralPartialEq for ExtData[src]

Auto Trait Implementations

Blanket Implementations

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

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

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

impl<T> From<T> for T[src]

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

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

type Owned = T

The resulting type after obtaining ownership.

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

type Error = Infallible

The type returned in the event of a conversion error.

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

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

The type returned in the event of a conversion error.