Trait darpi::request::FromRequestBody[][src]

pub trait FromRequestBody<T, E> where
    T: DeserializeOwned + 'static,
    E: ResponderError + 'static, 
{ #[must_use] pub fn extract<'life0, 'async_trait>(
        headers: &'life0 HeaderMap<HeaderValue>,
        b: Body
    ) -> Pin<Box<dyn Future<Output = Result<T, E>> + 'async_trait + Send, Global>>
    where
        'life0: 'async_trait
; #[must_use] pub fn assert_content_type<'life0, 'async_trait>(
        _content_type: Option<&'life0 HeaderValue>
    ) -> Pin<Box<dyn Future<Output = Result<(), E>> + 'async_trait + Send, Global>>
    where
        'life0: 'async_trait
, { ... } }

Required methods

#[must_use]pub fn extract<'life0, 'async_trait>(
    headers: &'life0 HeaderMap<HeaderValue>,
    b: Body
) -> Pin<Box<dyn Future<Output = Result<T, E>> + 'async_trait + Send, Global>> where
    'life0: 'async_trait, 
[src]

Loading content...

Provided methods

#[must_use]pub fn assert_content_type<'life0, 'async_trait>(
    _content_type: Option<&'life0 HeaderValue>
) -> Pin<Box<dyn Future<Output = Result<(), E>> + 'async_trait + Send, Global>> where
    'life0: 'async_trait, 
[src]

Loading content...

Implementors

impl<T> FromRequestBody<Json<T>, JsonErr> for Json<T> where
    T: DeserializeOwned + 'static, 
[src]

impl<T> FromRequestBody<Xml<T>, XmlErr> for Xml<T> where
    T: DeserializeOwned + 'static, 
[src]

impl<T> FromRequestBody<Yaml<T>, YamlErr> for Yaml<T> where
    T: DeserializeOwned + 'static, 
[src]

Loading content...