pub trait IsValidatorInactive<AccountId> {
// Required method
fn is_inactive(
era: EraIndex,
stash: &AccountId,
points: &[(ServiceKind, RewardPoint)],
) -> bool;
}Expand description
Check if validator was inactive at some era.
The check is based on the RewardPoints the validator received during the era, per
[ServiceKind].
Required Methods§
Sourcefn is_inactive(
era: EraIndex,
stash: &AccountId,
points: &[(ServiceKind, RewardPoint)],
) -> bool
fn is_inactive( era: EraIndex, stash: &AccountId, points: &[(ServiceKind, RewardPoint)], ) -> bool
Tell if the validator is considered inactive in era, given its points per service.
A service the validator earned nothing for may be missing from points. Points of eras
before they were recorded per service count as [ServiceKind::RelayConsensus].
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.
Implementations on Foreign Types§
Source§impl<AccountId> IsValidatorInactive<AccountId> for ()
A validator is never inactive, so no validator can be chilled for inactivity.
impl<AccountId> IsValidatorInactive<AccountId> for ()
A validator is never inactive, so no validator can be chilled for inactivity.