referrerpolicy=no-referrer-when-downgrade
pallet_staking_runtime_api

Trait StakingApi

Source
pub trait StakingApi<Block: BlockT, Balance, AccountId>: Core<Block>
where Balance: Codec, AccountId: Codec,
{ // Provided methods fn nominations_quota( &self, __runtime_api_at_param__: <Block as BlockT>::Hash, balance: Balance, ) -> Result<u32, ApiError> { ... } fn eras_stakers_page_count( &self, __runtime_api_at_param__: <Block as BlockT>::Hash, era: EraIndex, account: AccountId, ) -> Result<Page, ApiError> { ... } fn pending_rewards( &self, __runtime_api_at_param__: <Block as BlockT>::Hash, era: EraIndex, account: AccountId, ) -> Result<bool, ApiError> { ... } }

Provided Methods§

Source

fn nominations_quota( &self, __runtime_api_at_param__: <Block as BlockT>::Hash, balance: Balance, ) -> Result<u32, ApiError>

Returns the nominations quota for a nominator with a given balance.

Source

fn eras_stakers_page_count( &self, __runtime_api_at_param__: <Block as BlockT>::Hash, era: EraIndex, account: AccountId, ) -> Result<Page, ApiError>

Returns the page count of exposures for a validator account in a given era.

Source

fn pending_rewards( &self, __runtime_api_at_param__: <Block as BlockT>::Hash, era: EraIndex, account: AccountId, ) -> Result<bool, ApiError>

Returns true if validator account has pages to be claimed for the given era.

Trait Implementations§

Source§

impl<Block: BlockT, Balance, AccountId> RuntimeApiInfo for dyn StakingApi<Block, Balance, AccountId>

Source§

const ID: [u8; 8] = _

The identifier of the runtime api.
Source§

const VERSION: u32 = 1u32

The version of the runtime api.

Implementors§

impl<__SrApiBlock__: BlockT, RuntimeApiImplCall: CallApiAt<__SrApiBlock__> + 'static> StakingApi<__SrApiBlock__, u128, <<MultiSignature as Verify>::Signer as IdentifyAccount>::AccountId> for RuntimeApiImpl<__SrApiBlock__, RuntimeApiImplCall>
where RuntimeApiImplCall::StateBackend: StateBackend<HashingFor<__SrApiBlock__>>, &'static RuntimeApiImplCall: Send,

impl<__SrApiBlock__: BlockT, RuntimeApiImplCall: CallApiAt<__SrApiBlock__> + 'static> StakingApi<__SrApiBlock__, u128, <<MultiSignature as Verify>::Signer as IdentifyAccount>::AccountId> for RuntimeApiImpl<__SrApiBlock__, RuntimeApiImplCall>
where RuntimeApiImplCall::StateBackend: StateBackend<HashingFor<__SrApiBlock__>>, &'static RuntimeApiImplCall: Send,