pub trait Handler<T>:
Clone
+ Send
+ Sync
+ 'static {
type Future: Future<Output = Response> + Send + 'static;
// Required method
fn call(&self, req: Request) -> Self::Future;
}Expand description
A trait for handling HTTP requests
Required Associated Types§
Required Methods§
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.