Skip to main content

ErasedHandler

Trait ErasedHandler 

Source
pub trait ErasedHandler:
    Send
    + Sync
    + 'static {
    // Required method
    fn call(
        &self,
        req: Request,
    ) -> Pin<Box<dyn Future<Output = Response> + Send + '_>>;
}

Required Methods§

Source

fn call( &self, req: Request, ) -> Pin<Box<dyn Future<Output = Response> + Send + '_>>

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<H, T> ErasedHandler for HandlerWrapper<H, T>
where H: Handler<T>, T: Send + Sync + 'static,