[][src]Trait pallet_elections_phragmen::Trait

Associated Types

type Event: From<Event<Self>> + Into<Self::Event>

The overarching event type.c

type ModuleId: Get<LockIdentifier>

Identifier for the elections-phragmen pallet's lock

type Currency: LockableCurrency<Self::AccountId, Moment = Self::BlockNumber> + ReservableCurrency<Self::AccountId>

The currency that people are electing with.

type ChangeMembers: ChangeMembers<Self::AccountId>

What to do when the members change.

type InitializeMembers: InitializeMembers<Self::AccountId>

What to do with genesis members

type CurrencyToVote: Convert<<Self::Currency as Currency<Self::AccountId>>::Balance, VoteWeight> + Convert<ExtendedBalance, <Self::Currency as Currency<Self::AccountId>>::Balance>

Convert a balance into a number used for election calculation. This must fit into a u64 but is allowed to be sensibly lossy.

type CandidacyBond: Get<<Self::Currency as Currency<Self::AccountId>>::Balance>

How much should be locked up in order to submit one's candidacy.

type VotingBond: Get<<Self::Currency as Currency<Self::AccountId>>::Balance>

How much should be locked up in order to be able to submit votes.

type LoserCandidate: OnUnbalanced<<Self::Currency as Currency<Self::AccountId>>::NegativeImbalance>

Handler for the unbalanced reduction when a candidate has lost (and is not a runner-up)

type BadReport: OnUnbalanced<<Self::Currency as Currency<Self::AccountId>>::NegativeImbalance>

Handler for the unbalanced reduction when a reporter has submitted a bad defunct report.

type KickedMember: OnUnbalanced<<Self::Currency as Currency<Self::AccountId>>::NegativeImbalance>

Handler for the unbalanced reduction when a member has been kicked.

type DesiredMembers: Get<u32>

Number of members to elect.

type DesiredRunnersUp: Get<u32>

Number of runners_up to keep.

type TermDuration: Get<Self::BlockNumber>

How long each seat is kept. This defines the next block number at which an election round will happen. If set to zero, no elections are ever triggered and the module will be in passive mode.

Loading content...

Implementors

Loading content...