Skip to main content

Controller

Trait Controller 

Source
pub trait Controller: 'static {
    // Required method
    fn mount(container: &Container, route: Route) -> Route;
}
Expand description

Implemented automatically by the #[routes] macro. Each controller mounts its routes (prefixed with the controller’s PATH) onto a parent Route.

Required Methods§

Source

fn mount(container: &Container, route: Route) -> Route

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§