covert_framework/extract/
mod.rs

1mod extension;
2mod json;
3mod path;
4mod query;
5
6use covert_types::{error::ApiError, request::Request};
7pub use extension::*;
8pub use json::*;
9pub use path::*;
10pub use query::*;
11
12pub trait FromRequest: Sized {
13    /// Perform the extraction.
14    ///
15    /// # Errors
16    ///
17    /// Returns error if the extraction from the [`Request`] was unsuccessful.
18    fn from_request(req: &mut Request) -> Result<Self, ApiError>;
19}