pub trait Middleware:
Send
+ Sync
+ 'static {
// Required method
fn handle(
&self,
request: BootRequest,
) -> BoxFuture<'static, Result<MiddlewareOutcome>>;
}Expand description
Request middleware that runs before guards, interceptors, pipes, and handlers.
Required Methods§
fn handle( &self, request: BootRequest, ) -> BoxFuture<'static, Result<MiddlewareOutcome>>
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".