Skip to main content

GovernanceReadApiClient

Trait GovernanceReadApiClient 

Source
pub trait GovernanceReadApiClient: ClientT {
    // Provided methods
    fn get_stakes_by_ids<'life0, 'async_trait>(
        &'life0 self,
        staked_iota_ids: Vec<ObjectId>,
    ) -> Pin<Box<dyn Future<Output = Result<Vec<DelegatedStake>, Error>> + Send + 'async_trait>>
       where Self: Sync + 'async_trait,
             'life0: 'async_trait { ... }
    fn get_stakes<'life0, 'async_trait>(
        &'life0 self,
        owner: Address,
    ) -> Pin<Box<dyn Future<Output = Result<Vec<DelegatedStake>, Error>> + Send + 'async_trait>>
       where Self: Sync + 'async_trait,
             'life0: 'async_trait { ... }
    fn get_timelocked_stakes_by_ids<'life0, 'async_trait>(
        &'life0 self,
        timelocked_staked_iota_ids: Vec<ObjectId>,
    ) -> Pin<Box<dyn Future<Output = Result<Vec<DelegatedTimelockedStake>, Error>> + Send + 'async_trait>>
       where Self: Sync + 'async_trait,
             'life0: 'async_trait { ... }
    fn get_timelocked_stakes<'life0, 'async_trait>(
        &'life0 self,
        owner: Address,
    ) -> Pin<Box<dyn Future<Output = Result<Vec<DelegatedTimelockedStake>, Error>> + Send + 'async_trait>>
       where Self: Sync + 'async_trait,
             'life0: 'async_trait { ... }
    fn get_committee_info<'life0, 'async_trait>(
        &'life0 self,
        epoch: Option<BigInt<u64>>,
    ) -> Pin<Box<dyn Future<Output = Result<IotaCommittee, Error>> + Send + 'async_trait>>
       where Self: Sync + 'async_trait,
             'life0: 'async_trait { ... }
    fn get_latest_iota_system_state_v2<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = Result<IotaSystemStateSummary, Error>> + Send + 'async_trait>>
       where Self: Sync + 'async_trait,
             'life0: 'async_trait { ... }
    fn get_latest_iota_system_state<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = Result<IotaSystemStateSummaryV1, Error>> + Send + 'async_trait>>
       where Self: Sync + 'async_trait,
             'life0: 'async_trait { ... }
    fn get_reference_gas_price<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = Result<BigInt<u64>, Error>> + Send + 'async_trait>>
       where Self: Sync + 'async_trait,
             'life0: 'async_trait { ... }
    fn get_validators_apy<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = Result<ValidatorApys, Error>> + Send + 'async_trait>>
       where Self: Sync + 'async_trait,
             'life0: 'async_trait { ... }
}
Expand description

Client implementation for the GovernanceReadApi RPC API.

Provided Methods§

Source

fn get_stakes_by_ids<'life0, 'async_trait>( &'life0 self, staked_iota_ids: Vec<ObjectId>, ) -> Pin<Box<dyn Future<Output = Result<Vec<DelegatedStake>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait, 'life0: 'async_trait,

Return one or more [DelegatedStake]. If a Stake was withdrawn its status will be Unstaked.

Source

fn get_stakes<'life0, 'async_trait>( &'life0 self, owner: Address, ) -> Pin<Box<dyn Future<Output = Result<Vec<DelegatedStake>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait, 'life0: 'async_trait,

Return all [DelegatedStake].

Source

fn get_timelocked_stakes_by_ids<'life0, 'async_trait>( &'life0 self, timelocked_staked_iota_ids: Vec<ObjectId>, ) -> Pin<Box<dyn Future<Output = Result<Vec<DelegatedTimelockedStake>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait, 'life0: 'async_trait,

Return one or more [DelegatedTimelockedStake]. If a Stake was withdrawn its status will be Unstaked.

Source

fn get_timelocked_stakes<'life0, 'async_trait>( &'life0 self, owner: Address, ) -> Pin<Box<dyn Future<Output = Result<Vec<DelegatedTimelockedStake>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait, 'life0: 'async_trait,

Return all [DelegatedTimelockedStake].

Source

fn get_committee_info<'life0, 'async_trait>( &'life0 self, epoch: Option<BigInt<u64>>, ) -> Pin<Box<dyn Future<Output = Result<IotaCommittee, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait, 'life0: 'async_trait,

Return the committee information for the asked epoch.

Source

fn get_latest_iota_system_state_v2<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<IotaSystemStateSummary, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait, 'life0: 'async_trait,

Return the latest IOTA system state object on networks supporting protocol version >= 5. These are networks with node software release version >= 0.11.

Source

fn get_latest_iota_system_state<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<IotaSystemStateSummaryV1, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait, 'life0: 'async_trait,

👎Deprecated since 0.11.0:

Use get_latest_iota_system_state_v2 instead

Return the latest IOTA system state object on networks supporting protocol version < 5. These are networks with node software release version < 0.11.

Source

fn get_reference_gas_price<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<BigInt<u64>, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait, 'life0: 'async_trait,

Return the reference gas price for the network

Source

fn get_validators_apy<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<ValidatorApys, Error>> + Send + 'async_trait>>
where Self: Sync + 'async_trait, 'life0: 'async_trait,

Return the validator APY

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<TypeJsonRpseeInteral> GovernanceReadApiClient for TypeJsonRpseeInteral
where TypeJsonRpseeInteral: ClientT,