parse static method
Parses source
as Alpha-2, alpha-3 or numeric country code
The source
must be either 2-3 ASCII uppercase letters of alpha code,
or 2-3 digits of numeric code
Throws FormatException
if the code is not valid country code
Implementation
static CountryCode parse(String source) {
var c = _parse(source);
if (c == null) {
throw FormatException('Invalid or non-assigned code', source);
}
return c;
}