pub trait Application {
type Router: RouterExt<State = Self::State>;
type State;
// Provided methods
fn register_extension(
_: &State<Self::State>,
router: AxumRouter<Self::State>,
) -> AxumRouter<Self::State> { ... }
fn register_layer(
_: &State<Self::State>,
router: AxumRouter<Self::State>,
) -> AxumRouter<Self::State> { ... }
fn register_middleware(
_: &State<Self::State>,
router: AxumRouter<Self::State>,
) -> AxumRouter<Self::State> { ... }
fn register_service(server: Server<Self::State>) -> Server<Self::State> { ... }
}
Expand description
Interface d’application web.
Required Associated Types§
Provided Methods§
fn register_extension( _: &State<Self::State>, router: AxumRouter<Self::State>, ) -> AxumRouter<Self::State>
fn register_layer( _: &State<Self::State>, router: AxumRouter<Self::State>, ) -> AxumRouter<Self::State>
fn register_middleware( _: &State<Self::State>, router: AxumRouter<Self::State>, ) -> AxumRouter<Self::State>
fn register_service(server: Server<Self::State>) -> Server<Self::State>
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.