pub trait ChainExtensionInstance {
    type Instance;

    // Required method
    fn instantiate() -> Self::Instance;
}
Expand description

Trait implemented by chain extensions.

Allows to use the self.env().extension().my_chain_extension(...) syntax.

Note

This trait is automatically implemented when using #[ink::chain_extension] procedural macro.

Required Associated Types§

source

type Instance

The type of the chain extension instance.

Required Methods§

source

fn instantiate() -> Self::Instance

Creates a new instance of the chain extension to use methods with method chaining syntax.

Object Safety§

This trait is not object safe.

Implementors§