pub trait Config: Config + Config {
    type MomentIntoBalance: Convert<Self::Moment, BalanceOf<Self>>;
    type Currency: Currency<Self::AccountId>;
    type MaxPastReeval: Get<u32>;
    type MembersCount: Get<BalanceOf<Self>>;
    type MembersStorage: StoredMap<Self::AccountId, FirstEligibleUd>;
    type RuntimeEvent: From<Event<Self>> + IsType<<Self as Config>::RuntimeEvent>;
    type SquareMoneyGrowthRate: Get<Perbill>;
    type UdCreationPeriod: Get<Self::Moment>;
    type UdReevalPeriod: Get<Self::Moment>;
    type UnitsPerUd: Get<BalanceOf<Self>>;
    type WeightInfo: WeightInfo;
    type AccountIdOf: Convert<u32, Option<Self::AccountId>>;
}
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§

source

type MomentIntoBalance: Convert<Self::Moment, BalanceOf<Self>>

source

type Currency: Currency<Self::AccountId>

source

type MaxPastReeval: Get<u32>

Maximum number of past UD revaluations to keep in storage.

source

type MembersCount: Get<BalanceOf<Self>>

Somethings that must provide the number of accounts allowed to create the universal dividend

source

type MembersStorage: StoredMap<Self::AccountId, FirstEligibleUd>

Somethings that must provide the list of accounts ids allowed to create the universal dividend

source

type RuntimeEvent: From<Event<Self>> + IsType<<Self as Config>::RuntimeEvent>

Because this pallet emits events, it depends on the runtime’s definition of an event.

source

type SquareMoneyGrowthRate: Get<Perbill>

Square of the money growth rate per ud reevaluation period

source

type UdCreationPeriod: Get<Self::Moment>

Universal dividend creation period (ms)

source

type UdReevalPeriod: Get<Self::Moment>

Universal dividend reevaluation period (ms)

source

type UnitsPerUd: Get<BalanceOf<Self>>

The number of units to divide the amounts expressed in number of UDs Example: If you wish to express the UD amounts with a maximum precision of the order of the milliUD, choose 1000

source

type WeightInfo: WeightInfo

Pallet weights info

source

type AccountIdOf: Convert<u32, Option<Self::AccountId>>

Object Safety§

This trait is not object safe.

Implementors§