Trait polkadot_service::runtime_traits::Convert [−][src]
pub trait Convert<A, B> {
fn convert(a: A) -> B;
}
Expand description
Extensible conversion trait. Generic over both source and destination types.
Required methods
Implementations on Foreign Types
impl<T> Convert<u64, <<T as Config>::OnChargeTransaction as OnChargeTransaction<T>>::Balance> for Pallet<T> where
T: Config,
<<T as Config>::OnChargeTransaction as OnChargeTransaction<T>>::Balance: FixedPointOperand,
impl<T> Convert<u64, <<T as Config>::OnChargeTransaction as OnChargeTransaction<T>>::Balance> for Pallet<T> where
T: Config,
<<T as Config>::OnChargeTransaction as OnChargeTransaction<T>>::Balance: FixedPointOperand,
pub fn convert(
weight: u64
) -> <<T as Config>::OnChargeTransaction as OnChargeTransaction<T>>::Balance
pub fn convert(
weight: u64
) -> <<T as Config>::OnChargeTransaction as OnChargeTransaction<T>>::Balance
Compute the fee for the specified weight.
This fee is already adjusted by the per block fee adjustment factor and is therefore the share that the weight contributes to the overall fee of a transaction. It is mainly for informational purposes and not used in the actual fee calculation.