Skip to main content

SmartFeatureContext

Trait SmartFeatureContext 

Source
pub trait SmartFeatureContext {
    type Tx: TransactionCommonFields;

    // Required method
    fn tx(&self) -> &Self::Tx;
}
Expand description

Narrow context trait shared by all Smart Escrow and Smart Contract entry points.

Provides access to the current transaction via an associated type bound to TransactionCommonFields. Kept intentionally minimal.

Concrete context types (EscrowFinishContext, ContractCallContext) implement this trait and expose their feature-unique host functions as inherent methods.

Required Associated Types§

Required Methods§

Source

fn tx(&self) -> &Self::Tx

Dyn Compatibility§

This trait is dyn compatible.

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

Implementors§