Trait ContainsCallVariant
pub trait ContainsCallVariant {
// Required method
fn contains(pallet_index: u8, call_index: u8) -> bool;
}Expand description
A trait for querying whether a type can be said to “contain” a call variant of the runtime.
A call variant is one call of one pallet, whatever the arguments of the call: one variant of
the Call enum of one pallet. It is identified by the index of the pallet in the runtime, as
PalletInfoAccess::index gives it, and by the index of the
call in the pallet, as GetCallIndex gives it.
In this order, these two indices are the first two bytes of an encoded runtime call. So the variant of an encoded call can be looked for without decoding the call.
Required Methods§
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.