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§

source

type T: ValidateArgs<'a>

The data type to validate using this arguments

Required Methods§

source

fn get(&'a self) -> <<Self as Arguments<'a>>::T as ValidateArgs<'a>>::Args

This method gets the arguments required by ValidateArgs::validate_args

Implementors§