pub trait PrepareMiddlewareEffect<S>: Sized + 'static {
type Middleware: Layer<S> + 'static;
// Required method
fn take(self, states: &mut StateCollector) -> Self::Middleware;
}
Expand description
prepare for Middleware
it can adding middleware and state
Required Associated Types§
type Middleware: Layer<S> + 'static
Required Methods§
fn take(self, states: &mut StateCollector) -> Self::Middleware
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.