Trait HandlerSimpleAsync

Source
pub trait HandlerSimpleAsync
where Self: Send + Sync + 'static,
{ type Future: Future<Output = ServerResult<Response<Body>>> + Send + 'static; // Required method fn handle(&self, _request: Request<Body>) -> Self::Future; // Provided method fn wrap(self) -> HandlerSimpleAsyncWrapper<Self> where Self: Sized { ... } }

Required Associated Types§

Source

type Future: Future<Output = ServerResult<Response<Body>>> + Send + 'static

Required Methods§

Source

fn handle(&self, _request: Request<Body>) -> Self::Future

Provided Methods§

Source

fn wrap(self) -> HandlerSimpleAsyncWrapper<Self>
where Self: Sized,

Implementors§