MithrilStakeDistributionAggregatorRequest

Trait MithrilStakeDistributionAggregatorRequest 

Source
pub trait MithrilStakeDistributionAggregatorRequest: Send + Sync {
    // Required methods
    fn list_latest<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = MithrilResult<Vec<MithrilStakeDistributionListItem>>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn get_by_hash<'life0, 'life1, 'async_trait>(
        &'life0 self,
        hash: &'life1 str,
    ) -> Pin<Box<dyn Future<Output = MithrilResult<Option<MithrilStakeDistribution>>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
}
Expand description

Define the requests against an aggregator related to Mithril stake distribution.

Required Methods§

Source

fn list_latest<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = MithrilResult<Vec<MithrilStakeDistributionListItem>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get the list of latest Mithril stake distributions from the aggregator.

Source

fn get_by_hash<'life0, 'life1, 'async_trait>( &'life0 self, hash: &'life1 str, ) -> Pin<Box<dyn Future<Output = MithrilResult<Option<MithrilStakeDistribution>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Get a Mithril stake distribution for a given hash from the aggregator.

Implementations on Foreign Types§

Source§

impl MithrilStakeDistributionAggregatorRequest for AggregatorHttpClient

Source§

fn list_latest<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = MithrilResult<Vec<MithrilStakeDistributionListItem>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source§

fn get_by_hash<'life0, 'life1, 'async_trait>( &'life0 self, hash: &'life1 str, ) -> Pin<Box<dyn Future<Output = MithrilResult<Option<MithrilStakeDistribution>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Implementors§