referrerpolicy=no-referrer-when-downgrade

Trait xcm_emulator::ProcessMessage

pub trait ProcessMessage {
    type Origin: FullCodec + MaxEncodedLen + Clone + Eq + PartialEq + TypeInfo + Debug;

    // Required method
    fn process_message(
        message: &[u8],
        origin: Self::Origin,
        meter: &mut WeightMeter,
        id: &mut [u8; 32],
    ) -> Result<bool, ProcessMessageError>;
}
Expand description

Can process messages from a specific origin.

Required Associated Types§

type Origin: FullCodec + MaxEncodedLen + Clone + Eq + PartialEq + TypeInfo + Debug

The transport from where a message originates.

Required Methods§

fn process_message( message: &[u8], origin: Self::Origin, meter: &mut WeightMeter, id: &mut [u8; 32], ) -> Result<bool, ProcessMessageError>

Process the given message, using no more than the remaining meter weight to do so.

Returns whether the message was processed.

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

§

impl<MessageOrigin, XcmExecutor, Call> ProcessMessage for ProcessXcmMessage<MessageOrigin, XcmExecutor, Call>
where MessageOrigin: Into<Location> + FullCodec + MaxEncodedLen + Clone + Eq + PartialEq + TypeInfo + Debug, XcmExecutor: ExecuteXcm<Call>, Call: Decode + GetDispatchInfo,

§

fn process_message( message: &[u8], origin: <ProcessXcmMessage<MessageOrigin, XcmExecutor, Call> as ProcessMessage>::Origin, meter: &mut WeightMeter, id: &mut [u8; 32], ) -> Result<bool, ProcessMessageError>

Process the given message, using no more than the remaining weight to do so.

§

type Origin = MessageOrigin

§

impl<Origin, const REQUIRED_WEIGHT: u64> ProcessMessage for NoopMessageProcessor<Origin, REQUIRED_WEIGHT>
where Origin: FullCodec + MaxEncodedLen + Clone + Eq + PartialEq + TypeInfo + Debug,

§

type Origin = Origin

§

fn process_message( _message: &[u8], _origin: <NoopMessageProcessor<Origin, REQUIRED_WEIGHT> as ProcessMessage>::Origin, meter: &mut WeightMeter, _id: &mut [u8; 32], ) -> Result<bool, ProcessMessageError>

Implementors§