pub trait PoolInspect<AccountId, CurrencyId> {
    type PoolId;
    type TrancheId;
    type Moment;

    // Required methods
    fn pool_exists(pool_id: Self::PoolId) -> bool;
    fn tranche_exists(
        pool_id: Self::PoolId,
        tranche_id: Self::TrancheId
    ) -> bool;
    fn account_for(pool_id: Self::PoolId) -> AccountId;
    fn currency_for(pool_id: Self::PoolId) -> Option<CurrencyId>;
}
Expand description

A trait that support pool inspection operations such as pool existence checks and pool admin of permission set.

Required Associated Types§

Required Methods§

source

fn pool_exists(pool_id: Self::PoolId) -> bool

Check if the pool exists

source

fn tranche_exists(pool_id: Self::PoolId, tranche_id: Self::TrancheId) -> bool

Check if the tranche exists for the given pool

source

fn account_for(pool_id: Self::PoolId) -> AccountId

Get the account used for the given pool_id.

source

fn currency_for(pool_id: Self::PoolId) -> Option<CurrencyId>

Get the currency used for the given pool_id.

Object Safety§

This trait is not object safe.

Implementors§