pub trait Transfer<AccountId>: Inspect<AccountId> {
// Required method
fn transfer(
asset: Self::AssetId,
source: &AccountId,
dest: &AccountId,
amount: Self::Balance,
keep_alive: bool
) -> Result<Self::Balance, DispatchError>;
// Provided methods
fn deactivate(_: Self::AssetId, _: Self::Balance) { ... }
fn reactivate(_: Self::AssetId, _: Self::Balance) { ... }
}
Expand description
Trait for providing a set of named fungible assets which can only be transferred.
Required Methods§
sourcefn transfer(
asset: Self::AssetId,
source: &AccountId,
dest: &AccountId,
amount: Self::Balance,
keep_alive: bool
) -> Result<Self::Balance, DispatchError>
fn transfer( asset: Self::AssetId, source: &AccountId, dest: &AccountId, amount: Self::Balance, keep_alive: bool ) -> Result<Self::Balance, DispatchError>
Transfer funds from one account into another.
Provided Methods§
sourcefn deactivate(_: Self::AssetId, _: Self::Balance)
fn deactivate(_: Self::AssetId, _: Self::Balance)
Reduce the active issuance by some amount.
sourcefn reactivate(_: Self::AssetId, _: Self::Balance)
fn reactivate(_: Self::AssetId, _: Self::Balance)
Increase the active issuance by some amount, up to the outstanding amount reduced.