pub trait Handler<Args> {
type Output: IntoResponse;
// Required method
fn call(self, req: &mut Request) -> Self::Output;
}Expand description
Trait for request handlers.
This trait is implemented for functions that take extractors and return
something that implements IntoResponse. You typically don’t need to
implement this trait manually - it’s automatically implemented for
functions with up to 6 extractor arguments.
Required Associated Types§
Sourcetype Output: IntoResponse
type Output: IntoResponse
The response type returned by this handler.