[loc-en-dev] getISO3Language and getISO3Country

Yoshito Umaoka y.umaoka at gmail.com
Fri Sep 18 10:17:04 PDT 2009


I have several questions about getISO3Language and getISO3Country.

With the support for some ISO 639-2/639-3/639-5 three letter codes in 
Locale, getISO3Language should be updated.  For example,

new Locale("kok").getISO3Language();

should return "kok", because it's a three letter valid ISO 639-2 code, 
conforming to the BCP 47 language tag.

Q1: What if an unassigned 3 letter code is used?  For example -

new Locale("zzz").getISO3Language();

Q2: What if 3 an ill-formed 3 letter code is used?  For example -

new Locale("123").getISO3Language();

Also, a question for getISO3Country.  We will support UN M.49 area code.

Q3. What if M.49 code is used?  For example -

new Locale("en", "029").getISO3Country()

In addition to this, the current getISO3Country JavaDoc mentions ISO 
3166-2, which looks inappropriate to me.  What this method is handling 
is ISO 3166-1 alpha-2 codes and ISO 3166-1 alpha-3 codes.  The API doc 
is referencing to http://www.davros.org/misc/iso3166.txt .  It looks 
this is a personal web site and the data is already out of date.  
Unfortunately, ISO 3166 maintenance agency does not disclose ISO 3166-1 
alpha-3 code data.  But we obviously want a reference which is public 
and stable.  I think wikipedia has a topic for ISO 3166-1 and contains 
the code list -> http://en.wikipedia.org/wiki/ISO_3166-1  I think this 
reference would work better than the current.  What do you think?

-Yoshito


More information about the locale-enhancement-dev mailing list