Current section
Files
Jump to
Current section
Files
src/iso_erlang_validator.erl
-module(iso_erlang_validator).
%% API
-export([
is_country_upper/1,
is_country_alpha_2_upper/1,
is_country_alpha_3_upper/1
]).
%% @doc Checks if the given bitstring is a valid two letter country code (ISO alpha-2) OR
%% a valid three letter country code (ISO alpha-3). This is case-sensitive (Expects uppercase).
%% @end
is_country_upper(Country) when bit_size(Country) =:= 16 -> is_country_alpha_2_upper(Country);
is_country_upper(Country) when bit_size(Country) =:= 24 -> is_country_alpha_3_upper(Country);
is_country_upper(_Other) -> false.
%% @doc Checks if the given bitstring is a valid three letter country code (ISO alpha-3).
%% This is case-sensitive (Expects uppercase).
%% @end
is_country_alpha_3_upper(<<"AFG">>) -> true;
is_country_alpha_3_upper(<<"ALA">>) -> true;
is_country_alpha_3_upper(<<"ALB">>) -> true;
is_country_alpha_3_upper(<<"DZA">>) -> true;
is_country_alpha_3_upper(<<"ASM">>) -> true;
is_country_alpha_3_upper(<<"AND">>) -> true;
is_country_alpha_3_upper(<<"AGO">>) -> true;
is_country_alpha_3_upper(<<"AIA">>) -> true;
is_country_alpha_3_upper(<<"ATA">>) -> true;
is_country_alpha_3_upper(<<"ATG">>) -> true;
is_country_alpha_3_upper(<<"ARG">>) -> true;
is_country_alpha_3_upper(<<"ARM">>) -> true;
is_country_alpha_3_upper(<<"ABW">>) -> true;
is_country_alpha_3_upper(<<"AUS">>) -> true;
is_country_alpha_3_upper(<<"AUT">>) -> true;
is_country_alpha_3_upper(<<"AZE">>) -> true;
is_country_alpha_3_upper(<<"BHS">>) -> true;
is_country_alpha_3_upper(<<"BHR">>) -> true;
is_country_alpha_3_upper(<<"BGD">>) -> true;
is_country_alpha_3_upper(<<"BRB">>) -> true;
is_country_alpha_3_upper(<<"BLR">>) -> true;
is_country_alpha_3_upper(<<"BEL">>) -> true;
is_country_alpha_3_upper(<<"BLZ">>) -> true;
is_country_alpha_3_upper(<<"BEN">>) -> true;
is_country_alpha_3_upper(<<"BMU">>) -> true;
is_country_alpha_3_upper(<<"BTN">>) -> true;
is_country_alpha_3_upper(<<"BOL">>) -> true;
is_country_alpha_3_upper(<<"BIH">>) -> true;
is_country_alpha_3_upper(<<"BWA">>) -> true;
is_country_alpha_3_upper(<<"BVT">>) -> true;
is_country_alpha_3_upper(<<"BRA">>) -> true;
is_country_alpha_3_upper(<<"VGB">>) -> true;
is_country_alpha_3_upper(<<"IOT">>) -> true;
is_country_alpha_3_upper(<<"BRN">>) -> true;
is_country_alpha_3_upper(<<"BGR">>) -> true;
is_country_alpha_3_upper(<<"BFA">>) -> true;
is_country_alpha_3_upper(<<"BDI">>) -> true;
is_country_alpha_3_upper(<<"KHM">>) -> true;
is_country_alpha_3_upper(<<"CMR">>) -> true;
is_country_alpha_3_upper(<<"CAN">>) -> true;
is_country_alpha_3_upper(<<"CPV">>) -> true;
is_country_alpha_3_upper(<<"CYM">>) -> true;
is_country_alpha_3_upper(<<"CAF">>) -> true;
is_country_alpha_3_upper(<<"TCD">>) -> true;
is_country_alpha_3_upper(<<"CHL">>) -> true;
is_country_alpha_3_upper(<<"CHN">>) -> true;
is_country_alpha_3_upper(<<"HKG">>) -> true;
is_country_alpha_3_upper(<<"MAC">>) -> true;
is_country_alpha_3_upper(<<"CXR">>) -> true;
is_country_alpha_3_upper(<<"CCK">>) -> true;
is_country_alpha_3_upper(<<"COL">>) -> true;
is_country_alpha_3_upper(<<"COM">>) -> true;
is_country_alpha_3_upper(<<"COG">>) -> true;
is_country_alpha_3_upper(<<"COD">>) -> true;
is_country_alpha_3_upper(<<"COK">>) -> true;
is_country_alpha_3_upper(<<"CRI">>) -> true;
is_country_alpha_3_upper(<<"CIV">>) -> true;
is_country_alpha_3_upper(<<"HRV">>) -> true;
is_country_alpha_3_upper(<<"CUB">>) -> true;
is_country_alpha_3_upper(<<"CYP">>) -> true;
is_country_alpha_3_upper(<<"CZE">>) -> true;
is_country_alpha_3_upper(<<"DNK">>) -> true;
is_country_alpha_3_upper(<<"DJI">>) -> true;
is_country_alpha_3_upper(<<"DMA">>) -> true;
is_country_alpha_3_upper(<<"DOM">>) -> true;
is_country_alpha_3_upper(<<"ECU">>) -> true;
is_country_alpha_3_upper(<<"EGY">>) -> true;
is_country_alpha_3_upper(<<"SLV">>) -> true;
is_country_alpha_3_upper(<<"GNQ">>) -> true;
is_country_alpha_3_upper(<<"ERI">>) -> true;
is_country_alpha_3_upper(<<"EST">>) -> true;
is_country_alpha_3_upper(<<"ETH">>) -> true;
is_country_alpha_3_upper(<<"FLK">>) -> true;
is_country_alpha_3_upper(<<"FRO">>) -> true;
is_country_alpha_3_upper(<<"FJI">>) -> true;
is_country_alpha_3_upper(<<"FIN">>) -> true;
is_country_alpha_3_upper(<<"FRA">>) -> true;
is_country_alpha_3_upper(<<"GUF">>) -> true;
is_country_alpha_3_upper(<<"PYF">>) -> true;
is_country_alpha_3_upper(<<"ATF">>) -> true;
is_country_alpha_3_upper(<<"GAB">>) -> true;
is_country_alpha_3_upper(<<"GMB">>) -> true;
is_country_alpha_3_upper(<<"GEO">>) -> true;
is_country_alpha_3_upper(<<"DEU">>) -> true;
is_country_alpha_3_upper(<<"GHA">>) -> true;
is_country_alpha_3_upper(<<"GIB">>) -> true;
is_country_alpha_3_upper(<<"GRC">>) -> true;
is_country_alpha_3_upper(<<"GRL">>) -> true;
is_country_alpha_3_upper(<<"GRD">>) -> true;
is_country_alpha_3_upper(<<"GLP">>) -> true;
is_country_alpha_3_upper(<<"GUM">>) -> true;
is_country_alpha_3_upper(<<"GTM">>) -> true;
is_country_alpha_3_upper(<<"GGY">>) -> true;
is_country_alpha_3_upper(<<"GIN">>) -> true;
is_country_alpha_3_upper(<<"GNB">>) -> true;
is_country_alpha_3_upper(<<"GUY">>) -> true;
is_country_alpha_3_upper(<<"HTI">>) -> true;
is_country_alpha_3_upper(<<"HMD">>) -> true;
is_country_alpha_3_upper(<<"VAT">>) -> true;
is_country_alpha_3_upper(<<"HND">>) -> true;
is_country_alpha_3_upper(<<"HUN">>) -> true;
is_country_alpha_3_upper(<<"ISL">>) -> true;
is_country_alpha_3_upper(<<"IND">>) -> true;
is_country_alpha_3_upper(<<"IDN">>) -> true;
is_country_alpha_3_upper(<<"IRN">>) -> true;
is_country_alpha_3_upper(<<"IRQ">>) -> true;
is_country_alpha_3_upper(<<"IRL">>) -> true;
is_country_alpha_3_upper(<<"IMN">>) -> true;
is_country_alpha_3_upper(<<"ISR">>) -> true;
is_country_alpha_3_upper(<<"ITA">>) -> true;
is_country_alpha_3_upper(<<"JAM">>) -> true;
is_country_alpha_3_upper(<<"JPN">>) -> true;
is_country_alpha_3_upper(<<"JEY">>) -> true;
is_country_alpha_3_upper(<<"JOR">>) -> true;
is_country_alpha_3_upper(<<"KAZ">>) -> true;
is_country_alpha_3_upper(<<"KEN">>) -> true;
is_country_alpha_3_upper(<<"KIR">>) -> true;
is_country_alpha_3_upper(<<"PRK">>) -> true;
is_country_alpha_3_upper(<<"KOR">>) -> true;
is_country_alpha_3_upper(<<"KWT">>) -> true;
is_country_alpha_3_upper(<<"KGZ">>) -> true;
is_country_alpha_3_upper(<<"LAO">>) -> true;
is_country_alpha_3_upper(<<"LVA">>) -> true;
is_country_alpha_3_upper(<<"LBN">>) -> true;
is_country_alpha_3_upper(<<"LSO">>) -> true;
is_country_alpha_3_upper(<<"LBR">>) -> true;
is_country_alpha_3_upper(<<"LBY">>) -> true;
is_country_alpha_3_upper(<<"LIE">>) -> true;
is_country_alpha_3_upper(<<"LTU">>) -> true;
is_country_alpha_3_upper(<<"LUX">>) -> true;
is_country_alpha_3_upper(<<"MKD">>) -> true;
is_country_alpha_3_upper(<<"MDG">>) -> true;
is_country_alpha_3_upper(<<"MWI">>) -> true;
is_country_alpha_3_upper(<<"MYS">>) -> true;
is_country_alpha_3_upper(<<"MDV">>) -> true;
is_country_alpha_3_upper(<<"MLI">>) -> true;
is_country_alpha_3_upper(<<"MLT">>) -> true;
is_country_alpha_3_upper(<<"MHL">>) -> true;
is_country_alpha_3_upper(<<"MTQ">>) -> true;
is_country_alpha_3_upper(<<"MRT">>) -> true;
is_country_alpha_3_upper(<<"MUS">>) -> true;
is_country_alpha_3_upper(<<"MYT">>) -> true;
is_country_alpha_3_upper(<<"MEX">>) -> true;
is_country_alpha_3_upper(<<"FSM">>) -> true;
is_country_alpha_3_upper(<<"MDA">>) -> true;
is_country_alpha_3_upper(<<"MCO">>) -> true;
is_country_alpha_3_upper(<<"MNG">>) -> true;
is_country_alpha_3_upper(<<"MNE">>) -> true;
is_country_alpha_3_upper(<<"MSR">>) -> true;
is_country_alpha_3_upper(<<"MAR">>) -> true;
is_country_alpha_3_upper(<<"MOZ">>) -> true;
is_country_alpha_3_upper(<<"MMR">>) -> true;
is_country_alpha_3_upper(<<"NAM">>) -> true;
is_country_alpha_3_upper(<<"NRU">>) -> true;
is_country_alpha_3_upper(<<"NPL">>) -> true;
is_country_alpha_3_upper(<<"NLD">>) -> true;
is_country_alpha_3_upper(<<"ANT">>) -> true;
is_country_alpha_3_upper(<<"NCL">>) -> true;
is_country_alpha_3_upper(<<"NZL">>) -> true;
is_country_alpha_3_upper(<<"NIC">>) -> true;
is_country_alpha_3_upper(<<"NER">>) -> true;
is_country_alpha_3_upper(<<"NGA">>) -> true;
is_country_alpha_3_upper(<<"NIU">>) -> true;
is_country_alpha_3_upper(<<"NFK">>) -> true;
is_country_alpha_3_upper(<<"MNP">>) -> true;
is_country_alpha_3_upper(<<"NOR">>) -> true;
is_country_alpha_3_upper(<<"OMN">>) -> true;
is_country_alpha_3_upper(<<"PAK">>) -> true;
is_country_alpha_3_upper(<<"PLW">>) -> true;
is_country_alpha_3_upper(<<"PSE">>) -> true;
is_country_alpha_3_upper(<<"PAN">>) -> true;
is_country_alpha_3_upper(<<"PNG">>) -> true;
is_country_alpha_3_upper(<<"PRY">>) -> true;
is_country_alpha_3_upper(<<"PER">>) -> true;
is_country_alpha_3_upper(<<"PHL">>) -> true;
is_country_alpha_3_upper(<<"PCN">>) -> true;
is_country_alpha_3_upper(<<"POL">>) -> true;
is_country_alpha_3_upper(<<"PRT">>) -> true;
is_country_alpha_3_upper(<<"PRI">>) -> true;
is_country_alpha_3_upper(<<"QAT">>) -> true;
is_country_alpha_3_upper(<<"REU">>) -> true;
is_country_alpha_3_upper(<<"ROU">>) -> true;
is_country_alpha_3_upper(<<"RUS">>) -> true;
is_country_alpha_3_upper(<<"RWA">>) -> true;
is_country_alpha_3_upper(<<"BLM">>) -> true;
is_country_alpha_3_upper(<<"SHN">>) -> true;
is_country_alpha_3_upper(<<"KNA">>) -> true;
is_country_alpha_3_upper(<<"LCA">>) -> true;
is_country_alpha_3_upper(<<"MAF">>) -> true;
is_country_alpha_3_upper(<<"SPM">>) -> true;
is_country_alpha_3_upper(<<"VCT">>) -> true;
is_country_alpha_3_upper(<<"WSM">>) -> true;
is_country_alpha_3_upper(<<"SMR">>) -> true;
is_country_alpha_3_upper(<<"STP">>) -> true;
is_country_alpha_3_upper(<<"SAU">>) -> true;
is_country_alpha_3_upper(<<"SEN">>) -> true;
is_country_alpha_3_upper(<<"SRB">>) -> true;
is_country_alpha_3_upper(<<"SYC">>) -> true;
is_country_alpha_3_upper(<<"SLE">>) -> true;
is_country_alpha_3_upper(<<"SGP">>) -> true;
is_country_alpha_3_upper(<<"SVK">>) -> true;
is_country_alpha_3_upper(<<"SVN">>) -> true;
is_country_alpha_3_upper(<<"SLB">>) -> true;
is_country_alpha_3_upper(<<"SOM">>) -> true;
is_country_alpha_3_upper(<<"ZAF">>) -> true;
is_country_alpha_3_upper(<<"SGS">>) -> true;
is_country_alpha_3_upper(<<"SSD">>) -> true;
is_country_alpha_3_upper(<<"ESP">>) -> true;
is_country_alpha_3_upper(<<"LKA">>) -> true;
is_country_alpha_3_upper(<<"SDN">>) -> true;
is_country_alpha_3_upper(<<"SUR">>) -> true;
is_country_alpha_3_upper(<<"SJM">>) -> true;
is_country_alpha_3_upper(<<"SWZ">>) -> true;
is_country_alpha_3_upper(<<"SWE">>) -> true;
is_country_alpha_3_upper(<<"CHE">>) -> true;
is_country_alpha_3_upper(<<"SYR">>) -> true;
is_country_alpha_3_upper(<<"TWN">>) -> true;
is_country_alpha_3_upper(<<"TJK">>) -> true;
is_country_alpha_3_upper(<<"TZA">>) -> true;
is_country_alpha_3_upper(<<"THA">>) -> true;
is_country_alpha_3_upper(<<"TLS">>) -> true;
is_country_alpha_3_upper(<<"TGO">>) -> true;
is_country_alpha_3_upper(<<"TKL">>) -> true;
is_country_alpha_3_upper(<<"TON">>) -> true;
is_country_alpha_3_upper(<<"TTO">>) -> true;
is_country_alpha_3_upper(<<"TUN">>) -> true;
is_country_alpha_3_upper(<<"TUR">>) -> true;
is_country_alpha_3_upper(<<"TKM">>) -> true;
is_country_alpha_3_upper(<<"TCA">>) -> true;
is_country_alpha_3_upper(<<"TUV">>) -> true;
is_country_alpha_3_upper(<<"UGA">>) -> true;
is_country_alpha_3_upper(<<"UKR">>) -> true;
is_country_alpha_3_upper(<<"ARE">>) -> true;
is_country_alpha_3_upper(<<"GBR">>) -> true;
is_country_alpha_3_upper(<<"USA">>) -> true;
is_country_alpha_3_upper(<<"UMI">>) -> true;
is_country_alpha_3_upper(<<"URY">>) -> true;
is_country_alpha_3_upper(<<"UZB">>) -> true;
is_country_alpha_3_upper(<<"VUT">>) -> true;
is_country_alpha_3_upper(<<"VEN">>) -> true;
is_country_alpha_3_upper(<<"VNM">>) -> true;
is_country_alpha_3_upper(<<"VIR">>) -> true;
is_country_alpha_3_upper(<<"WLF">>) -> true;
is_country_alpha_3_upper(<<"ESH">>) -> true;
is_country_alpha_3_upper(<<"YEM">>) -> true;
is_country_alpha_3_upper(<<"ZMB">>) -> true;
is_country_alpha_3_upper(<<"ZWE">>) -> true;
is_country_alpha_3_upper(_Other) -> false.
%% @doc Checks if the given bitstring is a valid two letter country code (ISO alpha-2).
%% This is case-sensitive (Expects uppercase).
%% @end
is_country_alpha_2_upper(<<"AF">>) -> true;
is_country_alpha_2_upper(<<"AX">>) -> true;
is_country_alpha_2_upper(<<"AL">>) -> true;
is_country_alpha_2_upper(<<"DZ">>) -> true;
is_country_alpha_2_upper(<<"AS">>) -> true;
is_country_alpha_2_upper(<<"AD">>) -> true;
is_country_alpha_2_upper(<<"AO">>) -> true;
is_country_alpha_2_upper(<<"AI">>) -> true;
is_country_alpha_2_upper(<<"AQ">>) -> true;
is_country_alpha_2_upper(<<"AG">>) -> true;
is_country_alpha_2_upper(<<"AR">>) -> true;
is_country_alpha_2_upper(<<"AM">>) -> true;
is_country_alpha_2_upper(<<"AW">>) -> true;
is_country_alpha_2_upper(<<"AU">>) -> true;
is_country_alpha_2_upper(<<"AT">>) -> true;
is_country_alpha_2_upper(<<"AZ">>) -> true;
is_country_alpha_2_upper(<<"BS">>) -> true;
is_country_alpha_2_upper(<<"BH">>) -> true;
is_country_alpha_2_upper(<<"BD">>) -> true;
is_country_alpha_2_upper(<<"BB">>) -> true;
is_country_alpha_2_upper(<<"BY">>) -> true;
is_country_alpha_2_upper(<<"BE">>) -> true;
is_country_alpha_2_upper(<<"BZ">>) -> true;
is_country_alpha_2_upper(<<"BJ">>) -> true;
is_country_alpha_2_upper(<<"BM">>) -> true;
is_country_alpha_2_upper(<<"BT">>) -> true;
is_country_alpha_2_upper(<<"BO">>) -> true;
is_country_alpha_2_upper(<<"BA">>) -> true;
is_country_alpha_2_upper(<<"BW">>) -> true;
is_country_alpha_2_upper(<<"BV">>) -> true;
is_country_alpha_2_upper(<<"BR">>) -> true;
is_country_alpha_2_upper(<<"VG">>) -> true;
is_country_alpha_2_upper(<<"IO">>) -> true;
is_country_alpha_2_upper(<<"BN">>) -> true;
is_country_alpha_2_upper(<<"BG">>) -> true;
is_country_alpha_2_upper(<<"BF">>) -> true;
is_country_alpha_2_upper(<<"BI">>) -> true;
is_country_alpha_2_upper(<<"KH">>) -> true;
is_country_alpha_2_upper(<<"CM">>) -> true;
is_country_alpha_2_upper(<<"CA">>) -> true;
is_country_alpha_2_upper(<<"CV">>) -> true;
is_country_alpha_2_upper(<<"KY">>) -> true;
is_country_alpha_2_upper(<<"CF">>) -> true;
is_country_alpha_2_upper(<<"TD">>) -> true;
is_country_alpha_2_upper(<<"CL">>) -> true;
is_country_alpha_2_upper(<<"CN">>) -> true;
is_country_alpha_2_upper(<<"HK">>) -> true;
is_country_alpha_2_upper(<<"MO">>) -> true;
is_country_alpha_2_upper(<<"CX">>) -> true;
is_country_alpha_2_upper(<<"CC">>) -> true;
is_country_alpha_2_upper(<<"CO">>) -> true;
is_country_alpha_2_upper(<<"KM">>) -> true;
is_country_alpha_2_upper(<<"CG">>) -> true;
is_country_alpha_2_upper(<<"CD">>) -> true;
is_country_alpha_2_upper(<<"CK">>) -> true;
is_country_alpha_2_upper(<<"CR">>) -> true;
is_country_alpha_2_upper(<<"CI">>) -> true;
is_country_alpha_2_upper(<<"HR">>) -> true;
is_country_alpha_2_upper(<<"CU">>) -> true;
is_country_alpha_2_upper(<<"CY">>) -> true;
is_country_alpha_2_upper(<<"CZ">>) -> true;
is_country_alpha_2_upper(<<"DK">>) -> true;
is_country_alpha_2_upper(<<"DJ">>) -> true;
is_country_alpha_2_upper(<<"DM">>) -> true;
is_country_alpha_2_upper(<<"DO">>) -> true;
is_country_alpha_2_upper(<<"EC">>) -> true;
is_country_alpha_2_upper(<<"EG">>) -> true;
is_country_alpha_2_upper(<<"SV">>) -> true;
is_country_alpha_2_upper(<<"GQ">>) -> true;
is_country_alpha_2_upper(<<"ER">>) -> true;
is_country_alpha_2_upper(<<"EE">>) -> true;
is_country_alpha_2_upper(<<"ET">>) -> true;
is_country_alpha_2_upper(<<"FK">>) -> true;
is_country_alpha_2_upper(<<"FO">>) -> true;
is_country_alpha_2_upper(<<"FJ">>) -> true;
is_country_alpha_2_upper(<<"FI">>) -> true;
is_country_alpha_2_upper(<<"FR">>) -> true;
is_country_alpha_2_upper(<<"GF">>) -> true;
is_country_alpha_2_upper(<<"PF">>) -> true;
is_country_alpha_2_upper(<<"TF">>) -> true;
is_country_alpha_2_upper(<<"GA">>) -> true;
is_country_alpha_2_upper(<<"GM">>) -> true;
is_country_alpha_2_upper(<<"GE">>) -> true;
is_country_alpha_2_upper(<<"DE">>) -> true;
is_country_alpha_2_upper(<<"GH">>) -> true;
is_country_alpha_2_upper(<<"GI">>) -> true;
is_country_alpha_2_upper(<<"GR">>) -> true;
is_country_alpha_2_upper(<<"GL">>) -> true;
is_country_alpha_2_upper(<<"GD">>) -> true;
is_country_alpha_2_upper(<<"GP">>) -> true;
is_country_alpha_2_upper(<<"GU">>) -> true;
is_country_alpha_2_upper(<<"GT">>) -> true;
is_country_alpha_2_upper(<<"GG">>) -> true;
is_country_alpha_2_upper(<<"GN">>) -> true;
is_country_alpha_2_upper(<<"GW">>) -> true;
is_country_alpha_2_upper(<<"GY">>) -> true;
is_country_alpha_2_upper(<<"HT">>) -> true;
is_country_alpha_2_upper(<<"HM">>) -> true;
is_country_alpha_2_upper(<<"VA">>) -> true;
is_country_alpha_2_upper(<<"HN">>) -> true;
is_country_alpha_2_upper(<<"HU">>) -> true;
is_country_alpha_2_upper(<<"IS">>) -> true;
is_country_alpha_2_upper(<<"IN">>) -> true;
is_country_alpha_2_upper(<<"ID">>) -> true;
is_country_alpha_2_upper(<<"IR">>) -> true;
is_country_alpha_2_upper(<<"IQ">>) -> true;
is_country_alpha_2_upper(<<"IE">>) -> true;
is_country_alpha_2_upper(<<"IM">>) -> true;
is_country_alpha_2_upper(<<"IL">>) -> true;
is_country_alpha_2_upper(<<"IT">>) -> true;
is_country_alpha_2_upper(<<"JM">>) -> true;
is_country_alpha_2_upper(<<"JP">>) -> true;
is_country_alpha_2_upper(<<"JE">>) -> true;
is_country_alpha_2_upper(<<"JO">>) -> true;
is_country_alpha_2_upper(<<"KZ">>) -> true;
is_country_alpha_2_upper(<<"KE">>) -> true;
is_country_alpha_2_upper(<<"KI">>) -> true;
is_country_alpha_2_upper(<<"KP">>) -> true;
is_country_alpha_2_upper(<<"KR">>) -> true;
is_country_alpha_2_upper(<<"KW">>) -> true;
is_country_alpha_2_upper(<<"KG">>) -> true;
is_country_alpha_2_upper(<<"LA">>) -> true;
is_country_alpha_2_upper(<<"LV">>) -> true;
is_country_alpha_2_upper(<<"LB">>) -> true;
is_country_alpha_2_upper(<<"LS">>) -> true;
is_country_alpha_2_upper(<<"LR">>) -> true;
is_country_alpha_2_upper(<<"LY">>) -> true;
is_country_alpha_2_upper(<<"LI">>) -> true;
is_country_alpha_2_upper(<<"LT">>) -> true;
is_country_alpha_2_upper(<<"LU">>) -> true;
is_country_alpha_2_upper(<<"MK">>) -> true;
is_country_alpha_2_upper(<<"MG">>) -> true;
is_country_alpha_2_upper(<<"MW">>) -> true;
is_country_alpha_2_upper(<<"MY">>) -> true;
is_country_alpha_2_upper(<<"MV">>) -> true;
is_country_alpha_2_upper(<<"ML">>) -> true;
is_country_alpha_2_upper(<<"MT">>) -> true;
is_country_alpha_2_upper(<<"MH">>) -> true;
is_country_alpha_2_upper(<<"MQ">>) -> true;
is_country_alpha_2_upper(<<"MR">>) -> true;
is_country_alpha_2_upper(<<"MU">>) -> true;
is_country_alpha_2_upper(<<"YT">>) -> true;
is_country_alpha_2_upper(<<"MX">>) -> true;
is_country_alpha_2_upper(<<"FM">>) -> true;
is_country_alpha_2_upper(<<"MD">>) -> true;
is_country_alpha_2_upper(<<"MC">>) -> true;
is_country_alpha_2_upper(<<"MN">>) -> true;
is_country_alpha_2_upper(<<"ME">>) -> true;
is_country_alpha_2_upper(<<"MS">>) -> true;
is_country_alpha_2_upper(<<"MA">>) -> true;
is_country_alpha_2_upper(<<"MZ">>) -> true;
is_country_alpha_2_upper(<<"MM">>) -> true;
is_country_alpha_2_upper(<<"NA">>) -> true;
is_country_alpha_2_upper(<<"NR">>) -> true;
is_country_alpha_2_upper(<<"NP">>) -> true;
is_country_alpha_2_upper(<<"NL">>) -> true;
is_country_alpha_2_upper(<<"AN">>) -> true;
is_country_alpha_2_upper(<<"NC">>) -> true;
is_country_alpha_2_upper(<<"NZ">>) -> true;
is_country_alpha_2_upper(<<"NI">>) -> true;
is_country_alpha_2_upper(<<"NE">>) -> true;
is_country_alpha_2_upper(<<"NG">>) -> true;
is_country_alpha_2_upper(<<"NU">>) -> true;
is_country_alpha_2_upper(<<"NF">>) -> true;
is_country_alpha_2_upper(<<"MP">>) -> true;
is_country_alpha_2_upper(<<"NO">>) -> true;
is_country_alpha_2_upper(<<"OM">>) -> true;
is_country_alpha_2_upper(<<"PK">>) -> true;
is_country_alpha_2_upper(<<"PW">>) -> true;
is_country_alpha_2_upper(<<"PS">>) -> true;
is_country_alpha_2_upper(<<"PA">>) -> true;
is_country_alpha_2_upper(<<"PG">>) -> true;
is_country_alpha_2_upper(<<"PY">>) -> true;
is_country_alpha_2_upper(<<"PE">>) -> true;
is_country_alpha_2_upper(<<"PH">>) -> true;
is_country_alpha_2_upper(<<"PN">>) -> true;
is_country_alpha_2_upper(<<"PL">>) -> true;
is_country_alpha_2_upper(<<"PT">>) -> true;
is_country_alpha_2_upper(<<"PR">>) -> true;
is_country_alpha_2_upper(<<"QA">>) -> true;
is_country_alpha_2_upper(<<"RE">>) -> true;
is_country_alpha_2_upper(<<"RO">>) -> true;
is_country_alpha_2_upper(<<"RU">>) -> true;
is_country_alpha_2_upper(<<"RW">>) -> true;
is_country_alpha_2_upper(<<"BL">>) -> true;
is_country_alpha_2_upper(<<"SH">>) -> true;
is_country_alpha_2_upper(<<"KN">>) -> true;
is_country_alpha_2_upper(<<"LC">>) -> true;
is_country_alpha_2_upper(<<"MF">>) -> true;
is_country_alpha_2_upper(<<"PM">>) -> true;
is_country_alpha_2_upper(<<"VC">>) -> true;
is_country_alpha_2_upper(<<"WS">>) -> true;
is_country_alpha_2_upper(<<"SM">>) -> true;
is_country_alpha_2_upper(<<"ST">>) -> true;
is_country_alpha_2_upper(<<"SA">>) -> true;
is_country_alpha_2_upper(<<"SN">>) -> true;
is_country_alpha_2_upper(<<"RS">>) -> true;
is_country_alpha_2_upper(<<"SC">>) -> true;
is_country_alpha_2_upper(<<"SL">>) -> true;
is_country_alpha_2_upper(<<"SG">>) -> true;
is_country_alpha_2_upper(<<"SK">>) -> true;
is_country_alpha_2_upper(<<"SI">>) -> true;
is_country_alpha_2_upper(<<"SB">>) -> true;
is_country_alpha_2_upper(<<"SO">>) -> true;
is_country_alpha_2_upper(<<"ZA">>) -> true;
is_country_alpha_2_upper(<<"GS">>) -> true;
is_country_alpha_2_upper(<<"SS">>) -> true;
is_country_alpha_2_upper(<<"ES">>) -> true;
is_country_alpha_2_upper(<<"LK">>) -> true;
is_country_alpha_2_upper(<<"SD">>) -> true;
is_country_alpha_2_upper(<<"SR">>) -> true;
is_country_alpha_2_upper(<<"SJ">>) -> true;
is_country_alpha_2_upper(<<"SZ">>) -> true;
is_country_alpha_2_upper(<<"SE">>) -> true;
is_country_alpha_2_upper(<<"CH">>) -> true;
is_country_alpha_2_upper(<<"SY">>) -> true;
is_country_alpha_2_upper(<<"TW">>) -> true;
is_country_alpha_2_upper(<<"TJ">>) -> true;
is_country_alpha_2_upper(<<"TZ">>) -> true;
is_country_alpha_2_upper(<<"TH">>) -> true;
is_country_alpha_2_upper(<<"TL">>) -> true;
is_country_alpha_2_upper(<<"TG">>) -> true;
is_country_alpha_2_upper(<<"TK">>) -> true;
is_country_alpha_2_upper(<<"TO">>) -> true;
is_country_alpha_2_upper(<<"TT">>) -> true;
is_country_alpha_2_upper(<<"TN">>) -> true;
is_country_alpha_2_upper(<<"TR">>) -> true;
is_country_alpha_2_upper(<<"TM">>) -> true;
is_country_alpha_2_upper(<<"TC">>) -> true;
is_country_alpha_2_upper(<<"TV">>) -> true;
is_country_alpha_2_upper(<<"UG">>) -> true;
is_country_alpha_2_upper(<<"UA">>) -> true;
is_country_alpha_2_upper(<<"AE">>) -> true;
is_country_alpha_2_upper(<<"GB">>) -> true;
is_country_alpha_2_upper(<<"US">>) -> true;
is_country_alpha_2_upper(<<"UM">>) -> true;
is_country_alpha_2_upper(<<"UY">>) -> true;
is_country_alpha_2_upper(<<"UZ">>) -> true;
is_country_alpha_2_upper(<<"VU">>) -> true;
is_country_alpha_2_upper(<<"VE">>) -> true;
is_country_alpha_2_upper(<<"VN">>) -> true;
is_country_alpha_2_upper(<<"VI">>) -> true;
is_country_alpha_2_upper(<<"WF">>) -> true;
is_country_alpha_2_upper(<<"EH">>) -> true;
is_country_alpha_2_upper(<<"YE">>) -> true;
is_country_alpha_2_upper(<<"ZM">>) -> true;
is_country_alpha_2_upper(<<"ZW">>) -> true;
is_country_alpha_2_upper(_Other) -> false.