Trait pallet_gear::BuiltinDispatcher
source · pub trait BuiltinDispatcher {
type Context;
type Error;
// Required methods
fn lookup<'a>(
&'a self,
id: &ProgramId,
) -> Option<BuiltinInfo<'a, Self::Context, Self::Error>>;
fn run(
&self,
context: BuiltinInfo<'_, Self::Context, Self::Error>,
dispatch: StoredDispatch,
gas_limit: u64,
) -> Vec<JournalNote>;
}
Expand description
A trait representing a registry that provides methods to lookup and run a builtin actor.
Required Associated Types§
Required Methods§
sourcefn lookup<'a>(
&'a self,
id: &ProgramId,
) -> Option<BuiltinInfo<'a, Self::Context, Self::Error>>
fn lookup<'a>( &'a self, id: &ProgramId, ) -> Option<BuiltinInfo<'a, Self::Context, Self::Error>>
Looks up a builtin actor by its actor id.