CosmosClient

Trait CosmosClient 

Source
pub trait CosmosClient {
    // Required methods
    fn query<'life0, 'life1, 'async_trait, I, O>(
        &'life0 self,
        msg: I,
        path: &'life1 str,
    ) -> Pin<Box<dyn Future<Output = Result<O, ChainError>> + Send + 'async_trait>>
       where Self: Sized + 'async_trait,
             I: Message + Default + IntoRequest<I> + 'static + 'async_trait,
             O: Message + Default + 'static + 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn simulate_tx<'life0, 'life1, 'async_trait>(
        &'life0 self,
        tx: &'life1 RawTx,
    ) -> Pin<Box<dyn Future<Output = Result<GasInfo, ChainError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn broadcast_tx<'life0, 'life1, 'async_trait>(
        &'life0 self,
        tx: &'life1 RawTx,
        mode: BroadcastMode,
    ) -> Pin<Box<dyn Future<Output = Result<AsyncChainTxResponse, ChainError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
    fn broadcast_tx_block<'life0, 'life1, 'async_trait>(
        &'life0 self,
        tx: &'life1 RawTx,
    ) -> Pin<Box<dyn Future<Output = Result<ChainTxResponse, ChainError>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
}

Required Methods§

Source

fn query<'life0, 'life1, 'async_trait, I, O>( &'life0 self, msg: I, path: &'life1 str, ) -> Pin<Box<dyn Future<Output = Result<O, ChainError>> + Send + 'async_trait>>
where Self: Sized + 'async_trait, I: Message + Default + IntoRequest<I> + 'static + 'async_trait, O: Message + Default + 'static + 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Source

fn simulate_tx<'life0, 'life1, 'async_trait>( &'life0 self, tx: &'life1 RawTx, ) -> Pin<Box<dyn Future<Output = Result<GasInfo, ChainError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Source

fn broadcast_tx<'life0, 'life1, 'async_trait>( &'life0 self, tx: &'life1 RawTx, mode: BroadcastMode, ) -> Pin<Box<dyn Future<Output = Result<AsyncChainTxResponse, ChainError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Source

fn broadcast_tx_block<'life0, 'life1, 'async_trait>( &'life0 self, tx: &'life1 RawTx, ) -> Pin<Box<dyn Future<Output = Result<ChainTxResponse, ChainError>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

TODO: Block BroadcastMode support is being dropped from future Cosmos-Sdk versions. Cosm-tome will continue to support it by broadcasting with the Sync mode and then polling the GetTransaction endpoint until it has been committed in the block.

Implementors§