pub trait WrappingHandler<E> {
// Provided methods
fn wrap_with<M: Fn(Handler<E>) -> Handler<E>>(
self,
middleware: M,
) -> Handler<E>
where Self: 'static + Fn(Request, Context) -> Result<Response<Body>, E> + Sized { ... }
fn handler(self) -> Handler<HandlerError>
where Self: 'static + Fn(Request, Context) -> Result<Response<Body>, E> + Sized,
E: Send + Sync + Fail + From<Error> { ... }
}Expand description
A trait that houses methods related to handlers that can be wrapped with middleware.