mirror of
https://github.com/tokio-rs/axum.git
synced 2024-12-29 15:49:16 +01:00
20 lines
329 B
Rust
20 lines
329 B
Rust
use axum::{
|
|
extract::{Extension, FromRequestParts},
|
|
response::Response,
|
|
};
|
|
|
|
#[derive(Clone, FromRequestParts)]
|
|
#[from_request(via(Extension))]
|
|
struct Extractor {
|
|
one: i32,
|
|
two: String,
|
|
three: bool,
|
|
}
|
|
|
|
fn assert_from_request()
|
|
where
|
|
Extractor: FromRequestParts<(), Rejection = Response>,
|
|
{
|
|
}
|
|
|
|
fn main() {}
|