pub trait WeightBounds<RuntimeCall> {
// Required methods
fn weight(message: &mut Xcm<RuntimeCall>) -> Result<Weight, ()>;
fn instr_weight(
instruction: &mut Instruction<RuntimeCall>,
) -> Result<Weight, ()>;
}
Expand description
Determine the weight of an XCM message.
Required Methods§
Sourcefn weight(message: &mut Xcm<RuntimeCall>) -> Result<Weight, ()>
fn weight(message: &mut Xcm<RuntimeCall>) -> Result<Weight, ()>
Return the maximum amount of weight that an attempted execution of this message could consume.
Sourcefn instr_weight(
instruction: &mut Instruction<RuntimeCall>,
) -> Result<Weight, ()>
fn instr_weight( instruction: &mut Instruction<RuntimeCall>, ) -> Result<Weight, ()>
Return the maximum amount of weight that an attempted execution of this instruction could consume.
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.