pub struct AppRouter { /* private fields */ }Expand description
Application router with common utilities
Implementations§
Source§impl AppRouter
impl AppRouter
pub fn new() -> Self
pub fn route(self, path: &str, method_router: MethodRouter<()>) -> Self
pub fn nest(self, path: &str, router: Router) -> Self
pub fn merge<R>(self, other: R) -> Self
pub fn fallback(self, method_router: MethodRouter<()>) -> Self
pub fn build(self) -> Router
Trait Implementations§
Auto Trait Implementations§
impl Freeze for AppRouter
impl !RefUnwindSafe for AppRouter
impl Send for AppRouter
impl Sync for AppRouter
impl Unpin for AppRouter
impl !UnwindSafe for AppRouter
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more