Trait pallet_lbp::pallet::Config
source · pub trait Config: Config {
type Event: From<Event<Self>> + IsType<<Self as Config>::Event>;
type MultiCurrency: MultiCurrencyExtended<Self::AccountId, CurrencyId = AssetId, Amount = Amount, Balance = Balance> + MultiLockableCurrency<Self::AccountId>;
type LockedBalance: LockedBalance<AssetId, Self::AccountId, Balance>;
type CreatePoolOrigin: EnsureOrigin<Self::Origin>;
type LBPWeightFunction: LBPWeightCalculation<Self::BlockNumber>;
type AssetPairAccountId: AssetPairAccountIdFor<AssetId, <Self as Config>::AccountId>;
type WeightInfo: WeightInfo;
type MinTradingLimit: Get<Balance>;
type MinPoolLiquidity: Get<Balance>;
type MaxInRatio: Get<u128>;
type MaxOutRatio: Get<u128>;
type BlockNumberProvider: BlockNumberProvider<BlockNumber = Self::BlockNumber>;
}
Expand description
Configuration trait of this pallet.
Implement this type for a runtime in order to customize this pallet.
Required Associated Types§
type Event: From<Event<Self>> + IsType<<Self as Config>::Event>
sourcetype MultiCurrency: MultiCurrencyExtended<Self::AccountId, CurrencyId = AssetId, Amount = Amount, Balance = Balance> + MultiLockableCurrency<Self::AccountId>
type MultiCurrency: MultiCurrencyExtended<Self::AccountId, CurrencyId = AssetId, Amount = Amount, Balance = Balance> + MultiLockableCurrency<Self::AccountId>
Multi currency for transfer of currencies
sourcetype LockedBalance: LockedBalance<AssetId, Self::AccountId, Balance>
type LockedBalance: LockedBalance<AssetId, Self::AccountId, Balance>
Universal locked balance getter for tracking of fee collector balance
sourcetype CreatePoolOrigin: EnsureOrigin<Self::Origin>
type CreatePoolOrigin: EnsureOrigin<Self::Origin>
The origin which can create a new pool
sourcetype LBPWeightFunction: LBPWeightCalculation<Self::BlockNumber>
type LBPWeightFunction: LBPWeightCalculation<Self::BlockNumber>
Function for calculation of LBP weights
sourcetype AssetPairAccountId: AssetPairAccountIdFor<AssetId, <Self as Config>::AccountId>
type AssetPairAccountId: AssetPairAccountIdFor<AssetId, <Self as Config>::AccountId>
Mapping of asset pairs to unique pool identities
sourcetype WeightInfo: WeightInfo
type WeightInfo: WeightInfo
Weight information for the extrinsics
sourcetype MinTradingLimit: Get<Balance>
type MinTradingLimit: Get<Balance>
Minimum trading limit, sole purpose of this is to keep the math working
sourcetype MinPoolLiquidity: Get<Balance>
type MinPoolLiquidity: Get<Balance>
Minimum pool liquidity, sole purpose of this is to keep the math working
sourcetype MaxInRatio: Get<u128>
type MaxInRatio: Get<u128>
Max fraction of pool to sell in single transaction
sourcetype MaxOutRatio: Get<u128>
type MaxOutRatio: Get<u128>
Max fraction of pool to buy in single transaction
sourcetype BlockNumberProvider: BlockNumberProvider<BlockNumber = Self::BlockNumber>
type BlockNumberProvider: BlockNumberProvider<BlockNumber = Self::BlockNumber>
The block number provider