Function rust_iso3166::from_alpha2
source · [−]pub fn from_alpha2(alpha2: &str) -> Option<CountryCode>
Expand description
Returns the CountryCode with the given Alpha2 code, if exists. #Sample
let country = rust_iso3166::from_alpha2("AU");
assert_eq!("AUS", country.unwrap().alpha3);