pub trait ChainObserver: Sync + Send {
    // Required methods
    fn get_current_datums<'life0, 'life1, 'async_trait>(
        &'life0 self,
        address: &'life1 ChainAddress
    ) -> Pin<Box<dyn Future<Output = Result<Vec<TxDatum>, ChainObserverError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn get_current_epoch<'life0, 'async_trait>(
        &'life0 self
    ) -> Pin<Box<dyn Future<Output = Result<Option<Epoch>, ChainObserverError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn get_current_chain_point<'life0, 'async_trait>(
        &'life0 self
    ) -> Pin<Box<dyn Future<Output = Result<Option<ChainPoint>, ChainObserverError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn get_current_stake_distribution<'life0, 'async_trait>(
        &'life0 self
    ) -> Pin<Box<dyn Future<Output = Result<Option<StakeDistribution>, ChainObserverError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;

    // Provided method
    fn get_current_kes_period<'life0, 'life1, 'async_trait>(
        &'life0 self,
        _opcert: &'life1 OpCert
    ) -> Pin<Box<dyn Future<Output = Result<Option<KESPeriod>, ChainObserverError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait { ... }
}
Expand description

Retrieve data from the cardano network

Required Methods§

source

fn get_current_datums<'life0, 'life1, 'async_trait>( &'life0 self, address: &'life1 ChainAddress ) -> Pin<Box<dyn Future<Output = Result<Vec<TxDatum>, ChainObserverError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Retrieve the datums associated to an address

source

fn get_current_epoch<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<Option<Epoch>, ChainObserverError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Retrieve the current epoch of the Cardano network

source

fn get_current_chain_point<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<Option<ChainPoint>, ChainObserverError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Retrieve the current chain point of the Cardano network

source

fn get_current_stake_distribution<'life0, 'async_trait>( &'life0 self ) -> Pin<Box<dyn Future<Output = Result<Option<StakeDistribution>, ChainObserverError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Retrieve the current stake distribution of the Cardano network

Provided Methods§

source

fn get_current_kes_period<'life0, 'life1, 'async_trait>( &'life0 self, _opcert: &'life1 OpCert ) -> Pin<Box<dyn Future<Output = Result<Option<KESPeriod>, ChainObserverError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Retrieve the KES period of an operational certificate

Implementors§