Module validator

Source
Expand description

Provides the Validator trait used for validate the values of an Argument.

Structs§

RangeValidator
A Validator where a str is valid if can be parsed to type T and is within the specified range.
TypeValidator
A Validator where a str is considered valid if can be parsed to a type T.

Traits§

Validator
Exposes a method for check if an str value is a valid argument value.

Functions§

validate_range
Constructs a Validator for the given range.
validate_type
Constructs a Validator for the specified type.