A library to easily validate user input. Forked in order to update the regex
dependency.
Add this to your Cargo.toml
:
[dependencies]
validate = "*"
and this to your crate root:
extern crate validate;
use validate::*;
assert!(email().validate(&"[email protected]").is_ok());
assert!(bound(..3).validate(&2).is_ok())