Struct viz_core::Context [−][src]
Implementations
impl Context
[src]
pub fn new(req: Request) -> Self
[src]
pub fn method(&self) -> &Method
[src]
pub fn version(&self) -> Version
[src]
pub fn uri(&self) -> &Uri
[src]
pub fn path(&self) -> &str
[src]
pub fn query_str(&self) -> Option<&str>
[src]
pub fn host(&self) -> Option<&str>
[src]
pub fn header(&self, key: impl AsRef<str>) -> Option<&HeaderValue>
[src]
pub fn headers(&self) -> &HeaderMap
[src]
pub fn extensions(&self) -> &Extensions
[src]
pub fn extensions_mut(&mut self) -> &mut Extensions
[src]
pub fn take_body(&mut self) -> Option<Body>
[src]
pub fn middleware(&self) -> &Middlewares
[src]
pub fn middleware_mut(&mut self) -> &mut Middlewares
[src]
pub async fn extract<T: Extract>(&mut self) -> Result<T, T::Error>
[src]
pub async fn next(&mut self) -> Result<Response>
[src]
Trait Implementations
impl ContextExt for Context
[src]
impl ContextExt for Context
[src]
fn cookies(&mut self) -> Result<Cookies, CookiesError>
[src]
fn cookie(&self, name: &str) -> Option<Cookie<'_>>
[src]
impl ContextExt for Context
[src]
fn form<'a, T>(&'a mut self) -> BoxFuture<'a, Result<T, PayloadError>> where
T: DeserializeOwned + Send + Sync,
[src]
T: DeserializeOwned + Send + Sync,
impl ContextExt for Context
[src]
fn multipart(&mut self) -> Result<Multipart, PayloadError>
[src]
impl ContextExt for Context
[src]
fn params<T>(&self) -> Result<T, ParamsError> where
T: DeserializeOwned,
[src]
T: DeserializeOwned,
fn param<T>(&self, name: &str) -> Result<T, ParamsError> where
T: FromStr,
T::Err: Display,
[src]
T: FromStr,
T::Err: Display,
impl ContextExt for Context
[src]
fn query<T>(&self) -> Result<T, PayloadError> where
T: DeserializeOwned,
[src]
T: DeserializeOwned,
impl ContextExt for Context
[src]
impl From<Request<Body>> for Context
[src]
impl<'a, F, T> Handle<'a, Context> for HandlerWrapper<F, T> where
F: HandlerBase<T> + Send + Sync + 'static,
T: Extract + Send + Sync + 'static,
T::Error: Into<Response> + Send,
[src]
F: HandlerBase<T> + Send + Sync + 'static,
T: Extract + Send + Sync + 'static,
T::Error: Into<Response> + Send,
type Output = Result<Response>
Returns Output
fn call(&'a self, cx: &'a mut Context) -> BoxFuture<'a, Self::Output>
[src]
impl<'a, F, T> Handle<'a, Context> for HandlerSuper<F, T> where
F: for<'h> HandlerCamp<'h, T> + Send + Sync + 'static,
T: Extract + Send + Sync + 'static,
T::Error: Into<Response> + Send,
[src]
F: for<'h> HandlerCamp<'h, T> + Send + Sync + 'static,
T: Extract + Send + Sync + 'static,
T::Error: Into<Response> + Send,
Auto Trait Implementations
impl !RefUnwindSafe for Context
impl Send for Context
impl Sync for Context
impl Unpin for Context
impl !UnwindSafe for Context
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,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T> Instrument for T
[src]
pub fn instrument(self, span: Span) -> Instrumented<Self>
[src]
pub fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T> Instrument for T
[src]
pub fn instrument(self, span: Span) -> Instrumented<Self>
[src]
pub fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
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.
pub 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.
pub 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>,