Skip to main content

ClientCaller

Trait ClientCaller 

Source
pub trait ClientCaller: Send {
    type Facts: ClientFacts;

    // Required method
    fn send_req(
        &self,
        task: <Self::Facts as ClientFacts>::Task,
    ) -> impl Future<Output = ()> + Send;
}
Expand description

A trait to support sending request task in async text, for all router and connection pool implementations

Required Associated Types§

Required Methods§

Source

fn send_req( &self, task: <Self::Facts as ClientFacts>::Task, ) -> impl Future<Output = ()> + Send

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl<C: ClientCaller + Send + Sync> ClientCaller for Arc<C>

Source§

type Facts = <C as ClientCaller>::Facts

Source§

async fn send_req(&self, task: <Self::Facts as ClientFacts>::Task)

Implementors§