pub trait InputValidator<T> {
type Err;
// Required method
fn validate(&mut self, input: &T) -> Result<(), Self::Err>;
}Expand description
Trait for input validators.
A generic implementation for Fn(&str) -> Result<(), E> is provided
to facilitate development.