pub struct MiddlewareRoute { /* private fields */ }Expand description
Route selector used by MiddlewareConsumer.
Implementations§
Source§impl MiddlewareRoute
impl MiddlewareRoute
pub fn any(path: impl Into<String>) -> Result<Self>
pub fn all(path: impl Into<String>) -> Result<Self>
pub fn method(method: HttpMethod, path: impl Into<String>) -> Result<Self>
pub fn get(path: impl Into<String>) -> Result<Self>
pub fn post(path: impl Into<String>) -> Result<Self>
pub fn put(path: impl Into<String>) -> Result<Self>
pub fn patch(path: impl Into<String>) -> Result<Self>
pub fn delete(path: impl Into<String>) -> Result<Self>
pub fn options(path: impl Into<String>) -> Result<Self>
pub fn head(path: impl Into<String>) -> Result<Self>
pub fn path(&self) -> &str
pub fn http_method(&self) -> Option<HttpMethod>
Trait Implementations§
Source§impl Clone for MiddlewareRoute
impl Clone for MiddlewareRoute
Source§fn clone(&self) -> MiddlewareRoute
fn clone(&self) -> MiddlewareRoute
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for MiddlewareRoute
impl Debug for MiddlewareRoute
impl Eq for MiddlewareRoute
Source§impl PartialEq for MiddlewareRoute
impl PartialEq for MiddlewareRoute
impl StructuralPartialEq for MiddlewareRoute
Auto Trait Implementations§
impl Freeze for MiddlewareRoute
impl RefUnwindSafe for MiddlewareRoute
impl Send for MiddlewareRoute
impl Sync for MiddlewareRoute
impl Unpin for MiddlewareRoute
impl UnsafeUnpin for MiddlewareRoute
impl UnwindSafe for MiddlewareRoute
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