Struct ntex_router::Router
source · pub struct Router<T, U = ()> { /* private fields */ }Expand description
Resource router.
Implementations§
source§impl<T, U> Router<T, U>
impl<T, U> Router<T, U>
pub fn build() -> RouterBuilder<T, U>
pub fn recognize<R, P>(&self, resource: &mut R) -> Option<(&T, ResourceId)>where R: Resource<P>, P: ResourcePath,
pub fn recognize_mut<R, P>( &mut self, resource: &mut R ) -> Option<(&mut T, ResourceId)>where R: Resource<P>, P: ResourcePath,
pub fn recognize_checked<R, P, F>( &self, resource: &mut R, check: F ) -> Option<(&T, ResourceId)>where F: Fn(&R, Option<&U>) -> bool, R: Resource<P>, P: ResourcePath,
pub fn recognize_mut_checked<R, P, F>( &mut self, resource: &mut R, check: F ) -> Option<(&mut T, ResourceId)>where F: Fn(&R, Option<&U>) -> bool, R: Resource<P>, P: ResourcePath,
Trait Implementations§
Auto Trait Implementations§
impl<T, U> RefUnwindSafe for Router<T, U>where T: RefUnwindSafe, U: RefUnwindSafe,
impl<T, U> Send for Router<T, U>where T: Send, U: Send,
impl<T, U> Sync for Router<T, U>where T: Sync, U: Sync,
impl<T, U> Unpin for Router<T, U>where T: Unpin, U: Unpin,
impl<T, U> UnwindSafe for Router<T, U>where T: UnwindSafe, U: UnwindSafe,
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