Trait pallet_circuit::threevm::ThreeVm
pub trait ThreeVm<T, Balance>: Precompile<T, Balance> + Signaller<<T as Config>::Hash, Result = Result<SignalOpcode, DispatchError>> + Remuneration<T, Balance>where
T: Config,
Balance: Encode + Decode,{
// Required methods
fn peek_registry(
id: &<T as Config>::Hash
) -> Result<RegistryContract<<T as Config>::Hash, <T as Config>::AccountId, Balance, <<<T as Config>::Block as HeaderProvider>::HeaderT as Header>::Number>, DispatchError>;
fn from_registry<Module, ModuleGen>(
id: &<T as Config>::Hash,
module_generator: ModuleGen
) -> Result<Module, DispatchError>
where Module: ModuleOperations<T, Balance>,
ModuleGen: Fn(Vec<u8, Global>) -> Module;
fn instantiate_check(kind: &ContractType) -> Result<(), DispatchError>;
fn storage_check(kind: &ContractType) -> Result<(), DispatchError>;
fn volatile_check(kind: &ContractType) -> Result<(), DispatchError>;
fn remunerable_check(kind: &ContractType) -> Result<(), DispatchError>;
fn try_persist_author(
contract: &<T as Config>::AccountId,
author: Option<&AuthorInfo<<T as Config>::AccountId, Balance>>
) -> Result<(), DispatchError>;
fn try_remove_author(
contract: &<T as Config>::AccountId
) -> Result<(), DispatchError>;
}
Required Methods§
fn peek_registry( id: &<T as Config>::Hash ) -> Result<RegistryContract<<T as Config>::Hash, <T as Config>::AccountId, Balance, <<<T as Config>::Block as HeaderProvider>::HeaderT as Header>::Number>, DispatchError>
fn from_registry<Module, ModuleGen>(
id: &<T as Config>::Hash,
module_generator: ModuleGen
) -> Result<Module, DispatchError>where
Module: ModuleOperations<T, Balance>,
ModuleGen: Fn(Vec<u8, Global>) -> Module,
fn from_registry<Module, ModuleGen>( id: &<T as Config>::Hash, module_generator: ModuleGen ) -> Result<Module, DispatchError>where Module: ModuleOperations<T, Balance>, ModuleGen: Fn(Vec<u8, Global>) -> Module,
Allows creating a Module
from a binary blob from the contracts registry