Struct susanoo::Route
[−]
[src]
pub struct Route { /* fields omitted */ }
A route endpoint, which contains the instance of handler and middlewares
Methods
impl Route
[src]
fn new<S, H>(method: Method, pattern: S, handler: H) -> Self where
S: AsRef<str>,
H: Handler,
S: AsRef<str>,
H: Handler,
fn with_middleware<M: Middleware>(self, middleware: M) -> Self
fn get<S: AsRef<str>, H: Handler>(pattern: S, handler: H) -> Self
fn post<S: AsRef<str>, H: Handler>(pattern: S, handler: H) -> Self
fn put<S: AsRef<str>, H: Handler>(pattern: S, handler: H) -> Self
fn delete<S: AsRef<str>, H: Handler>(pattern: S, handler: H) -> Self
fn head<S: AsRef<str>, H: Handler>(pattern: S, handler: H) -> Self
fn pattern_str(&self) -> &str
Trait Implementations
impl Clone for Route
[src]
fn clone(&self) -> Route
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more