pub trait CallDispatcher<Call: Dispatchable> {
// Required method
fn dispatch(
call: Call,
origin: Call::RuntimeOrigin,
) -> Result<Call::PostInfo, DispatchErrorWithPostInfo<Call::PostInfo>>;
}
Expand description
Defines how a call is dispatched with given origin. Allows to customize call dispatch, such as adapting the origin based on the call or modifying the call.
Required Methods§
fn dispatch( call: Call, origin: Call::RuntimeOrigin, ) -> Result<Call::PostInfo, DispatchErrorWithPostInfo<Call::PostInfo>>
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.