Trait postmark::Query

source ·
pub trait Query<C> {
    type Result;

    // Required method
    fn execute<'life0, 'async_trait>(
        self,
        client: &'life0 C
    ) -> Pin<Box<dyn Future<Output = Self::Result> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
}
Expand description

A trait which represents an asynchronous query which may be made to a Postmark client.

Required Associated Types§

source

type Result

The Result of executing a query

Required Methods§

source

fn execute<'life0, 'async_trait>( self, client: &'life0 C ) -> Pin<Box<dyn Future<Output = Self::Result> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait,

Perform the query against the client.

Implementors§

source§

impl<T, C> Query<C> for Twhere T: Endpoint + Send + Sync, C: Client + Send + Sync,

Extension method to all Endpoints to execute themselves againts a query