pub trait ValidatorRewardsHandler {
    type AccountId;

    // Required methods
    fn validator_totals(era: EraIndex) -> Vec<(Self::AccountId, u128)>;
    fn add_rewards(rewards: impl IntoIterator<Item = (Self::AccountId, u32)>);
}

Required Associated Types§

Required Methods§

source

fn validator_totals(era: EraIndex) -> Vec<(Self::AccountId, u128)>

Returns total exposure of validators for the era

source

fn add_rewards(rewards: impl IntoIterator<Item = (Self::AccountId, u32)>)

Add reward for validators

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl<T> ValidatorRewardsHandler for Pallet<T>
where T: Config, <T as Config>::CurrencyBalance: Into<u128>,

§

type AccountId = <T as Config>::AccountId

source§

fn validator_totals(era: EraIndex) -> Vec<(Self::AccountId, u128)>

source§

fn add_rewards(rewards: impl IntoIterator<Item = (Self::AccountId, u32)>)

Implementors§