[−][src]Struct gotham::router::route::RouteImpl
Concrete type for a route in a Gotham web application. Values of this type are created by the
gotham::router::builder
API and held internally in the Router
for dispatching requests.
Implementations
impl<RM, PE, QSE> RouteImpl<RM, PE, QSE> where
RM: RouteMatcher,
PE: PathExtractor<Body>,
QSE: QueryStringExtractor<Body>,
[src]
RM: RouteMatcher,
PE: PathExtractor<Body>,
QSE: QueryStringExtractor<Body>,
pub fn new(
matcher: RM,
dispatcher: Box<dyn Dispatcher + Send + Sync>,
_extractors: Extractors<PE, QSE>,
delegation: Delegation
) -> Self
[src]
matcher: RM,
dispatcher: Box<dyn Dispatcher + Send + Sync>,
_extractors: Extractors<PE, QSE>,
delegation: Delegation
) -> Self
Creates a new RouteImpl
from the provided components.
Trait Implementations
impl<RM, PE, QSE> Route for RouteImpl<RM, PE, QSE> where
RM: RouteMatcher,
PE: PathExtractor<Body>,
QSE: QueryStringExtractor<Body>,
[src]
RM: RouteMatcher,
PE: PathExtractor<Body>,
QSE: QueryStringExtractor<Body>,
type ResBody = Body
The type of the response body. The requirements of Hyper are that this implements HttpBody
. Almost always, it will want to be hyper::Body
. Read more
fn is_match(&self, state: &State) -> Result<(), RouteNonMatch>
[src]
fn delegation(&self) -> Delegation
[src]
fn dispatch(&self, state: State) -> Pin<Box<HandlerFuture>>
[src]
fn extract_request_path<'a>(
&self,
state: &mut State,
params: SegmentMapping<'a>
) -> Result<(), ExtractorFailed>
[src]
&self,
state: &mut State,
params: SegmentMapping<'a>
) -> Result<(), ExtractorFailed>
fn extend_response_on_path_error(
&self,
state: &mut State,
res: &mut Response<Self::ResBody>
)
[src]
&self,
state: &mut State,
res: &mut Response<Self::ResBody>
)
fn extract_query_string(&self, state: &mut State) -> Result<(), ExtractorFailed>
[src]
fn extend_response_on_query_string_error(
&self,
state: &mut State,
res: &mut Response<Self::ResBody>
)
[src]
&self,
state: &mut State,
res: &mut Response<Self::ResBody>
)
Auto Trait Implementations
impl<RM, PE, QSE> RefUnwindSafe for RouteImpl<RM, PE, QSE>
impl<RM, PE, QSE> Send for RouteImpl<RM, PE, QSE> where
RM: Send,
RM: Send,
impl<RM, PE, QSE> Sync for RouteImpl<RM, PE, QSE> where
PE: Sync,
QSE: Sync,
RM: Sync,
PE: Sync,
QSE: Sync,
RM: Sync,
impl<RM, PE, QSE> Unpin for RouteImpl<RM, PE, QSE> where
PE: Unpin,
QSE: Unpin,
RM: Unpin,
PE: Unpin,
QSE: Unpin,
RM: Unpin,
impl<RM, PE, QSE> !UnwindSafe for RouteImpl<RM, PE, QSE>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,