pub trait SessionInterface<AccountId> {
// Required methods
fn report_offence(validator: AccountId, severity: OffenceSeverity);
fn validators() -> Vec<AccountId>;
fn prune_historical_up_to(up_to: SessionIndex);
}
Expand description
Means for interacting with a specialized version of the session
trait.
This is needed because Staking
sets the ValidatorIdOf
of the pallet_session::Config
Required Methods§
Sourcefn report_offence(validator: AccountId, severity: OffenceSeverity)
fn report_offence(validator: AccountId, severity: OffenceSeverity)
Report an offending validator.
Sourcefn validators() -> Vec<AccountId>
fn validators() -> Vec<AccountId>
Get the validators from session.
Sourcefn prune_historical_up_to(up_to: SessionIndex)
fn prune_historical_up_to(up_to: SessionIndex)
Prune historical session tries up to but not including the given index.
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.