Struct ntex::router::Path [−][src]
pub struct Path<T> { /* fields omitted */ }
Expand description
Resource path match information
If resource path contains variable patterns, Path
stores them.
Implementations
impl<T> Path<T> where
T: ResourcePath,
[src]
impl<T> Path<T> where
T: ResourcePath,
[src]pub fn new(path: T) -> Path<T>
[src]
pub fn get(&self, key: &str) -> Option<&str>
[src]
pub fn get(&self, key: &str) -> Option<&str>
[src]Get matched parameter by name without type conversion
pub fn unprocessed(&self) -> &str
[src]
pub fn unprocessed(&self) -> &str
[src]Get unprocessed part of the path
pub fn query(&self, key: &str) -> &str
[src]
pub fn query(&self, key: &str) -> &str
[src]Get matched parameter by name.
If keyed parameter is not available empty string is used as default value.
pub fn load<'de, U>(&'de self) -> Result<U, Error> where
U: Deserialize<'de>,
[src]
pub fn load<'de, U>(&'de self) -> Result<U, Error> where
U: Deserialize<'de>,
[src]Try to deserialize matching parameters to a specified type U
Trait Implementations
impl<'a, T> Index<&'a str> for Path<T> where
T: ResourcePath,
[src]
impl<'a, T> Index<&'a str> for Path<T> where
T: ResourcePath,
[src]impl<T> Index<usize> for Path<T> where
T: ResourcePath,
[src]
impl<T> Index<usize> for Path<T> where
T: ResourcePath,
[src]impl<T> Resource<T> for Path<T> where
T: ResourcePath,
[src]
impl<T> Resource<T> for Path<T> where
T: ResourcePath,
[src]Auto Trait Implementations
impl<T> RefUnwindSafe for Path<T> where
T: RefUnwindSafe,
T: RefUnwindSafe,
impl<T> Send for Path<T> where
T: Send,
T: Send,
impl<T> Sync for Path<T> where
T: Sync,
T: Sync,
impl<T> Unpin for Path<T> where
T: Unpin,
T: Unpin,
impl<T> UnwindSafe for Path<T> where
T: UnwindSafe,
T: UnwindSafe,
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> Instrument for T
[src]
impl<T> Instrument for T
[src]fn instrument(self, span: Span) -> Instrumented<Self>
[src]
fn instrument(self, span: Span) -> Instrumented<Self>
[src]Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
fn in_current_span(self) -> Instrumented<Self>
[src]
fn in_current_span(self) -> Instrumented<Self>
[src]impl<T> Same<T> for T
impl<T> Same<T> for T
type Output = T
type Output = T
Should always be Self
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more