pub struct CountryIso639Validator;Expand description
Validator for ISO639 country codes.
§Examples
use ic_dbms_api::prelude::{CountryIso639Validator, Validate, Value};
let validator = CountryIso639Validator;
let valid_country = Value::Text("en".into());
let invalid_country = Value::Text("xx".into());
assert!(validator.validate(&valid_country).is_ok());
assert!(validator.validate(&invalid_country).is_err());Trait Implementations§
Auto Trait Implementations§
impl Freeze for CountryIso639Validator
impl RefUnwindSafe for CountryIso639Validator
impl Send for CountryIso639Validator
impl Sync for CountryIso639Validator
impl Unpin for CountryIso639Validator
impl UnwindSafe for CountryIso639Validator
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more