pub trait RedeemApi<Block: BlockT, VaultId, Balance, AccountId, H256, RedeemRequest>: Core<Block>where
    VaultId: Codec,
    Balance: Codec,
    AccountId: Codec,
    H256: Codec,
    RedeemRequest: Codec,{
    // Provided methods
    fn get_redeem_requests(
        &self,
        __runtime_api_at_param__: <Block as BlockT>::Hash,
        account_id: AccountId
    ) -> Result<Vec<H256>, ApiError> { ... }
    fn get_vault_redeem_requests(
        &self,
        __runtime_api_at_param__: <Block as BlockT>::Hash,
        vault_id: AccountId
    ) -> Result<Vec<H256>, ApiError> { ... }
    fn get_premium_redeem_vaults(
        &self,
        __runtime_api_at_param__: <Block as BlockT>::Hash
    ) -> Result<Result<Vec<(VaultId, BalanceWrapper<Balance>)>, DispatchError>, ApiError> { ... }
}

Provided Methods§

source

fn get_redeem_requests( &self, __runtime_api_at_param__: <Block as BlockT>::Hash, account_id: AccountId ) -> Result<Vec<H256>, ApiError>

Get all redeem requests for a particular account

source

fn get_vault_redeem_requests( &self, __runtime_api_at_param__: <Block as BlockT>::Hash, vault_id: AccountId ) -> Result<Vec<H256>, ApiError>

Get all redeem requests for a particular vault

source

fn get_premium_redeem_vaults( &self, __runtime_api_at_param__: <Block as BlockT>::Hash ) -> Result<Result<Vec<(VaultId, BalanceWrapper<Balance>)>, DispatchError>, ApiError>

Get all vaults below the premium redeem threshold, ordered in descending order of this amount

Trait Implementations§

source§

impl<Block: BlockT, VaultId, Balance, AccountId, H256, RedeemRequest> RuntimeApiInfo for dyn RedeemApi<Block, VaultId, Balance, AccountId, H256, RedeemRequest>

source§

const ID: [u8; 8] = _

The identifier of the runtime api.
source§

const VERSION: u32 = 1u32

The version of the runtime api.

Implementors§