Trait pallet_block_rewards::pallet::Config
source · pub trait Config: Config {
Show 16 associated items
type RuntimeEvent: From<Event<Self>> + IsType<<Self as Config>::RuntimeEvent>;
type AdminOrigin: EnsureOrigin<Self::RuntimeOrigin>;
type Balance: Balance + MaxEncodedLen + FixedPointOperand + MaybeSerializeDeserialize;
type Weight: Parameter + MaxEncodedLen + EnsureAdd + Unsigned + FixedPointOperand + Default;
type Rewards: GroupRewards<Balance = Self::Balance, GroupId = u32> + AccountRewards<Self::AccountId, Balance = Self::Balance, CurrencyId = <Self as Config>::CurrencyId> + CurrencyGroupChange<GroupId = u32, CurrencyId = <Self as Config>::CurrencyId>;
type Tokens: Mutate<Self::AccountId> + Inspect<Self::AccountId, AssetId = <Self as Config>::CurrencyId, Balance = Self::Balance> + FungibleMutate<Self::AccountId> + FungibleInspect<Self::AccountId, Balance = Self::Balance>;
type CurrencyId: Parameter + Member + Copy + Ord + MaxEncodedLen;
type StakeCurrencyId: Get<<Self as Config>::CurrencyId>;
type StakeAmount: Get<<Self as Config>::Balance>;
type StakeGroupId: Get<u32>;
type MaxCollators: Get<u32> + TypeInfo + Debug + Clone + PartialEq;
type TreasuryPalletId: Get<PalletId>;
type AuthorityId: Member + Parameter + RuntimeAppPublic + MaybeSerializeDeserialize + MaxEncodedLen;
type Rate: Parameter + Member + FixedPointNumberExtension + MaybeSerializeDeserialize + MaxEncodedLen;
type Time: TimeAsSecs;
type WeightInfo: WeightInfo;
}
Expand description
Configuration trait of this pallet.
The main purpose of this trait is to act as an interface between this pallet and the runtime in which it is embedded in. A type, function, or constant in this trait is essentially left to be configured by the runtime that includes this pallet.
Consequently, a runtime that wants to include this pallet must implement this trait.
Required Associated Types§
type RuntimeEvent: From<Event<Self>> + IsType<<Self as Config>::RuntimeEvent>
sourcetype AdminOrigin: EnsureOrigin<Self::RuntimeOrigin>
type AdminOrigin: EnsureOrigin<Self::RuntimeOrigin>
Required origin for admin purposes for configuring groups and currencies.
sourcetype Balance: Balance + MaxEncodedLen + FixedPointOperand + MaybeSerializeDeserialize
type Balance: Balance + MaxEncodedLen + FixedPointOperand + MaybeSerializeDeserialize
Type used to handle balances.
sourcetype Weight: Parameter + MaxEncodedLen + EnsureAdd + Unsigned + FixedPointOperand + Default
type Weight: Parameter + MaxEncodedLen + EnsureAdd + Unsigned + FixedPointOperand + Default
Type used to handle group weights.
sourcetype Rewards: GroupRewards<Balance = Self::Balance, GroupId = u32> + AccountRewards<Self::AccountId, Balance = Self::Balance, CurrencyId = <Self as Config>::CurrencyId> + CurrencyGroupChange<GroupId = u32, CurrencyId = <Self as Config>::CurrencyId>
type Rewards: GroupRewards<Balance = Self::Balance, GroupId = u32> + AccountRewards<Self::AccountId, Balance = Self::Balance, CurrencyId = <Self as Config>::CurrencyId> + CurrencyGroupChange<GroupId = u32, CurrencyId = <Self as Config>::CurrencyId>
The reward system used.
sourcetype Tokens: Mutate<Self::AccountId> + Inspect<Self::AccountId, AssetId = <Self as Config>::CurrencyId, Balance = Self::Balance> + FungibleMutate<Self::AccountId> + FungibleInspect<Self::AccountId, Balance = Self::Balance>
type Tokens: Mutate<Self::AccountId> + Inspect<Self::AccountId, AssetId = <Self as Config>::CurrencyId, Balance = Self::Balance> + FungibleMutate<Self::AccountId> + FungibleInspect<Self::AccountId, Balance = Self::Balance>
The type used to handle currency minting and burning for collators.
sourcetype CurrencyId: Parameter + Member + Copy + Ord + MaxEncodedLen
type CurrencyId: Parameter + Member + Copy + Ord + MaxEncodedLen
The currency type of the artificial block rewards currency.
sourcetype StakeCurrencyId: Get<<Self as Config>::CurrencyId>
type StakeCurrencyId: Get<<Self as Config>::CurrencyId>
The identifier of the artificial block rewards currency which is minted and burned for collators.
sourcetype StakeAmount: Get<<Self as Config>::Balance>
type StakeAmount: Get<<Self as Config>::Balance>
The amount of the artificial block rewards currency which is minted and burned for collators.
sourcetype StakeGroupId: Get<u32>
type StakeGroupId: Get<u32>
The identifier of the collator group.
type MaxCollators: Get<u32> + TypeInfo + Debug + Clone + PartialEq
sourcetype TreasuryPalletId: Get<PalletId>
type TreasuryPalletId: Get<PalletId>
Treasury pallet
sourcetype AuthorityId: Member + Parameter + RuntimeAppPublic + MaybeSerializeDeserialize + MaxEncodedLen
type AuthorityId: Member + Parameter + RuntimeAppPublic + MaybeSerializeDeserialize + MaxEncodedLen
The identifier type for an authority.
sourcetype Rate: Parameter + Member + FixedPointNumberExtension + MaybeSerializeDeserialize + MaxEncodedLen
type Rate: Parameter + Member + FixedPointNumberExtension + MaybeSerializeDeserialize + MaxEncodedLen
The inflation rate type
sourcetype WeightInfo: WeightInfo
type WeightInfo: WeightInfo
Information of runtime weights