Trait axum::extract::FromRequest[][src]

pub trait FromRequest<B>: Sized {
    type Rejection: IntoResponse;
    fn from_request<'life0, 'async_trait>(
        req: &'life0 mut RequestParts<B>
    ) -> Pin<Box<dyn Future<Output = Result<Self, Self::Rejection>> + Send + 'async_trait>>
    where
        'life0: 'async_trait,
        Self: 'async_trait
; }
Expand description

Types that can be created from requests.

See the module docs for more details.

Associated Types

If the extractor fails it’ll use this “rejection” type. A rejection is a kind of error that can be converted into a response.

Required methods

Perform the extraction.

Implementations on Foreign Types

Implementors