Trait orml_traits::xcm_transfer::XcmTransfer
source · pub trait XcmTransfer<AccountId, Balance, CurrencyId> {
// Required methods
fn transfer(
who: AccountId,
currency_id: CurrencyId,
amount: Balance,
dest: Location,
dest_weight_limit: WeightLimit
) -> Result<Transferred<AccountId>, DispatchError>;
fn transfer_multiasset(
who: AccountId,
asset: Asset,
dest: Location,
dest_weight_limit: WeightLimit
) -> Result<Transferred<AccountId>, DispatchError>;
fn transfer_with_fee(
who: AccountId,
currency_id: CurrencyId,
amount: Balance,
fee: Balance,
dest: Location,
dest_weight_limit: WeightLimit
) -> Result<Transferred<AccountId>, DispatchError>;
fn transfer_multiasset_with_fee(
who: AccountId,
asset: Asset,
fee: Asset,
dest: Location,
dest_weight_limit: WeightLimit
) -> Result<Transferred<AccountId>, DispatchError>;
fn transfer_multicurrencies(
who: AccountId,
currencies: Vec<(CurrencyId, Balance)>,
fee_item: u32,
dest: Location,
dest_weight_limit: WeightLimit
) -> Result<Transferred<AccountId>, DispatchError>;
fn transfer_multiassets(
who: AccountId,
assets: Assets,
fee: Asset,
dest: Location,
dest_weight_limit: WeightLimit
) -> Result<Transferred<AccountId>, DispatchError>;
}
Expand description
Abstraction over cross-chain token transfers.
Required Methods§
sourcefn transfer(
who: AccountId,
currency_id: CurrencyId,
amount: Balance,
dest: Location,
dest_weight_limit: WeightLimit
) -> Result<Transferred<AccountId>, DispatchError>
fn transfer( who: AccountId, currency_id: CurrencyId, amount: Balance, dest: Location, dest_weight_limit: WeightLimit ) -> Result<Transferred<AccountId>, DispatchError>
Transfer local assets with given CurrencyId
and Amount
.
sourcefn transfer_multiasset(
who: AccountId,
asset: Asset,
dest: Location,
dest_weight_limit: WeightLimit
) -> Result<Transferred<AccountId>, DispatchError>
fn transfer_multiasset( who: AccountId, asset: Asset, dest: Location, dest_weight_limit: WeightLimit ) -> Result<Transferred<AccountId>, DispatchError>
Transfer Asset
assets.
sourcefn transfer_with_fee(
who: AccountId,
currency_id: CurrencyId,
amount: Balance,
fee: Balance,
dest: Location,
dest_weight_limit: WeightLimit
) -> Result<Transferred<AccountId>, DispatchError>
fn transfer_with_fee( who: AccountId, currency_id: CurrencyId, amount: Balance, fee: Balance, dest: Location, dest_weight_limit: WeightLimit ) -> Result<Transferred<AccountId>, DispatchError>
Transfer native currencies specifying the fee and amount as separate.
sourcefn transfer_multiasset_with_fee(
who: AccountId,
asset: Asset,
fee: Asset,
dest: Location,
dest_weight_limit: WeightLimit
) -> Result<Transferred<AccountId>, DispatchError>
fn transfer_multiasset_with_fee( who: AccountId, asset: Asset, fee: Asset, dest: Location, dest_weight_limit: WeightLimit ) -> Result<Transferred<AccountId>, DispatchError>
Transfer Asset
specifying the fee and amount as separate.
sourcefn transfer_multicurrencies(
who: AccountId,
currencies: Vec<(CurrencyId, Balance)>,
fee_item: u32,
dest: Location,
dest_weight_limit: WeightLimit
) -> Result<Transferred<AccountId>, DispatchError>
fn transfer_multicurrencies( who: AccountId, currencies: Vec<(CurrencyId, Balance)>, fee_item: u32, dest: Location, dest_weight_limit: WeightLimit ) -> Result<Transferred<AccountId>, DispatchError>
Transfer several currencies specifying the item to be used as fee.
sourcefn transfer_multiassets(
who: AccountId,
assets: Assets,
fee: Asset,
dest: Location,
dest_weight_limit: WeightLimit
) -> Result<Transferred<AccountId>, DispatchError>
fn transfer_multiassets( who: AccountId, assets: Assets, fee: Asset, dest: Location, dest_weight_limit: WeightLimit ) -> Result<Transferred<AccountId>, DispatchError>
Transfer several Asset
specifying the item to be used as fee.
Object Safety§
This trait is not object safe.