referrerpolicy=no-referrer-when-downgrade
pub trait LocalXcmChannelManager {
    type Error: Debug;

    // Required methods
    fn is_congested(with: &Location) -> bool;
    fn suspend_bridge(
        local_origin: &Location,
        bridge: BridgeId,
    ) -> Result<(), Self::Error>;
    fn resume_bridge(
        local_origin: &Location,
        bridge: BridgeId,
    ) -> Result<(), Self::Error>;
}
Expand description

Local XCM channel manager.

Required Associated Types§

type Error: Debug

Error that may be returned when suspending/resuming the bridge.

Required Methods§

fn is_congested(with: &Location) -> bool

Returns true if the channel with given location is currently congested.

The with is guaranteed to be in the same consensus. However, it may point to something below the chain level - like the contract or pallet instance, for example.

fn suspend_bridge( local_origin: &Location, bridge: BridgeId, ) -> Result<(), Self::Error>

Suspend the bridge, opened by given origin.

The local_origin is guaranteed to be in the same consensus. However, it may point to something below the chain level - like the contract or pallet instance, for example.

fn resume_bridge( local_origin: &Location, bridge: BridgeId, ) -> Result<(), Self::Error>

Resume the previously suspended bridge, opened by given origin.

The local_origin is guaranteed to be in the same consensus. However, it may point to something below the chain level - like the contract or pallet instance, for example.

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

§

impl LocalXcmChannelManager for ()

§

type Error = ()

§

fn is_congested(_with: &Location) -> bool

§

fn suspend_bridge( _local_origin: &Location, _bridge: BridgeId, ) -> Result<(), <() as LocalXcmChannelManager>::Error>

§

fn resume_bridge( _local_origin: &Location, _bridge: BridgeId, ) -> Result<(), <() as LocalXcmChannelManager>::Error>

Implementors§