Trait ResponseHandler

Source
pub trait ResponseHandler: Sized {
    type Response: Into<WrappedResponse>;

    // Required method
    fn handle<'life0, 'async_trait>(
        reader: &'life0 mut BufReader<TcpStream>,
    ) -> Pin<Box<dyn Future<Output = Result<Self::Response, Error>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
}
Expand description

Response Handler for Cmd

Required Associated Types§

Source

type Response: Into<WrappedResponse>

The type of response

Required Methods§

Source

fn handle<'life0, 'async_trait>( reader: &'life0 mut BufReader<TcpStream>, ) -> Pin<Box<dyn Future<Output = Result<Self::Response, Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

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.

Implementors§