Function pallet_assets::pallet::dispatchables::set_metadata
source · pub fn set_metadata<T: Config<I>, I: 'static>(
id: T::AssetIdParameter,
name: Vec<u8>,
symbol: Vec<u8>,
decimals: u8,
)
Expand description
Set the metadata for an asset.
Origin must be Signed and the sender should be the Owner of the asset id
.
Funds of sender are reserved according to the formula:
MetadataDepositBase + MetadataDepositPerByte * (name.len + symbol.len)
taking into
account any already reserved funds.
id
: The identifier of the asset to update.name
: The user friendly name of this asset. Limited in length byStringLimit
.symbol
: The exchange symbol for this asset. Limited in length byStringLimit
.decimals
: The number of decimals this asset uses to represent one unit.
Emits MetadataSet
.
Weight: O(1)
§Warning: Doc-Only
This function is an automatically generated, and is doc-only, uncallable
stub. See the real version in
Pallet::set_metadata
.