openzeppelin_monitor::services::blockchain

Trait StellarClientTrait

Source
pub trait StellarClientTrait {
    // Required methods
    fn get_transactions<'life0, 'async_trait>(
        &'life0 self,
        start_sequence: u32,
        end_sequence: Option<u32>,
    ) -> Pin<Box<dyn Future<Output = Result<Vec<StellarTransaction>, Error>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn get_events<'life0, 'async_trait>(
        &'life0 self,
        start_sequence: u32,
        end_sequence: Option<u32>,
    ) -> Pin<Box<dyn Future<Output = Result<Vec<StellarEvent>, Error>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
}
Expand description

Extended functionality specific to the Stellar blockchain

Required Methods§

Source

fn get_transactions<'life0, 'async_trait>( &'life0 self, start_sequence: u32, end_sequence: Option<u32>, ) -> Pin<Box<dyn Future<Output = Result<Vec<StellarTransaction>, Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Retrieves transactions within a sequence range

§Arguments
  • start_sequence - Starting sequence number
  • end_sequence - Optional ending sequence number. If None, only fetches start_sequence
§Returns
  • Result<Vec<StellarTransaction>, anyhow::Error> - Collection of transactions or error
Source

fn get_events<'life0, 'async_trait>( &'life0 self, start_sequence: u32, end_sequence: Option<u32>, ) -> Pin<Box<dyn Future<Output = Result<Vec<StellarEvent>, Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Retrieves events within a sequence range

§Arguments
  • start_sequence - Starting sequence number
  • end_sequence - Optional ending sequence number. If None, only fetches start_sequence
§Returns
  • Result<Vec<StellarEvent>, anyhow::Error> - Collection of events or error

Implementors§