referrerpolicy=no-referrer-when-downgrade
penpal_runtime::xcm_config

Type Alias PoolAssetsExchanger

Source
pub type PoolAssetsExchanger = SingleAssetExchangeAdapter<AssetConversion, NativeAndAssets, (TrustBackedAssetsAsLocation<TrustBackedAssetsPalletLocation, Balance, Location>, ForeignAssetsConvertedConcreteId), AccountId>;
Expand description

Asset converter for pool assets. Used to convert assets in pools to the asset required for fee payment. The pool must be between the first asset and the one required for fee payment. This type allows paying fees with any asset in a pool with the asset required for fee payment.

Aliased Type§

struct PoolAssetsExchanger(/* private fields */);

Trait Implementations

Source§

impl<AssetConversion, Fungibles, Matcher, AccountId> AssetExchange for SingleAssetExchangeAdapter<AssetConversion, Fungibles, Matcher, AccountId>
where AssetConversion: QuotePrice<Balance = u128, AssetKind = <Fungibles as Inspect<AccountId>>::AssetId> + SwapCredit<AccountId, Balance = u128, AssetKind = <Fungibles as Inspect<AccountId>>::AssetId, Credit = Imbalance<<Fungibles as Inspect<AccountId>>::AssetId, <Fungibles as Inspect<AccountId>>::Balance, <Fungibles as Balanced<AccountId>>::OnDropCredit, <Fungibles as Balanced<AccountId>>::OnDropDebt>>, Fungibles: Balanced<AccountId, Balance = u128>, Matcher: MatchesFungibles<<Fungibles as Inspect<AccountId>>::AssetId, <Fungibles as Inspect<AccountId>>::Balance>,

Source§

fn exchange_asset( _: Option<&Location>, give: AssetsInHolding, want: &Assets, maximal: bool, ) -> Result<AssetsInHolding, AssetsInHolding>

Handler for exchanging an asset. Read more
Source§

fn quote_exchange_price( give: &Assets, want: &Assets, maximal: bool, ) -> Option<Assets>

Handler for quoting the exchange price of two asset collections. Read more