Trait axum_valid::validator::Arguments
source · pub trait Arguments<'a> {
type T: ValidateArgs<'a>;
// Required method
fn get(&'a self) -> <<Self as Arguments<'a>>::T as ValidateArgs<'a>>::Args;
}Expand description
Arguments provides the validation arguments for the data type T.
This trait has an associated type T which represents the data type to
validate. T must implement the ValidateArgs trait which defines the
validation logic.
It’s important to mention that types implementing Arguments should be a part of the router’s state
(either through implementing FromRef<StateType> or by directly becoming the state)
to enable automatic arguments retrieval during validation.
Required Associated Types§
sourcetype T: ValidateArgs<'a>
type T: ValidateArgs<'a>
The data type to validate using this arguments