Return-Path: Delivered-To: apmail-incubator-harmony-dev-archive@www.apache.org Received: (qmail 91983 invoked from network); 10 Aug 2006 10:28:51 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 10 Aug 2006 10:28:51 -0000 Received: (qmail 63856 invoked by uid 500); 10 Aug 2006 10:28:50 -0000 Delivered-To: apmail-incubator-harmony-dev-archive@incubator.apache.org Received: (qmail 63137 invoked by uid 500); 10 Aug 2006 10:28:48 -0000 Mailing-List: contact harmony-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: harmony-dev@incubator.apache.org Delivered-To: mailing list harmony-dev@incubator.apache.org Received: (qmail 63123 invoked by uid 99); 10 Aug 2006 10:28:48 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 10 Aug 2006 03:28:48 -0700 X-ASF-Spam-Status: No, hits=0.5 required=10.0 tests=DNS_FROM_RFC_ABUSE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: domain of alex.blewitt@gmail.com designates 64.233.182.184 as permitted sender) Received: from [64.233.182.184] (HELO nf-out-0910.google.com) (64.233.182.184) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 10 Aug 2006 03:28:47 -0700 Received: by nf-out-0910.google.com with SMTP id p48so525833nfa for ; Thu, 10 Aug 2006 03:28:26 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=i78ispj+lJBXOfaiSl/AA0ax6HUM/tCqOoyUxONSn2SboIdM/HMqSEyyPeCw3X39ekt6XSMyJfDgpEWB96u058aPYqUxh7GwOvr4VVlurMaWwOPVR6H1gPfjgL2Sw6glzoh9KszM3yh4WOLqlQg7HCRu++mz0ctWCaaDD9gKTA0= Received: by 10.78.107.8 with SMTP id f8mr1146438huc; Thu, 10 Aug 2006 03:28:26 -0700 (PDT) Received: by 10.78.148.4 with HTTP; Thu, 10 Aug 2006 03:28:26 -0700 (PDT) Message-ID: <636fd28e0608100328pe3d2932wbdd25663ae6eb27d@mail.gmail.com> Date: Thu, 10 Aug 2006 11:28:26 +0100 From: "Alex Blewitt" To: harmony-dev@incubator.apache.org Subject: Re: Re: [classlib][luni] Our locale data is incomplete, and Locale("", "CD").getDisplayCountry() return different string compared with ISO3166-1 In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <473c46620608100049y6ad0d538ife9cb2bbea1be577@mail.gmail.com> <44DAEFEB.6080105@gmail.com> <473c46620608100204i585c476j8de7649b7f52ac9a@mail.gmail.com> X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N I think we should follow the ISO-3166 standard for everything; after all, that's the point of the standard :-) If the RI has bugs in, then fair enough, but the point of the ISO codes is to have a standard way of referencing it (CD) -- how it appears on displays shouldn't be important, and you shouldn't have code that depends on the display name when you've got the ISO code ... It's much easier to be strict about it now (and fix bugs as they get found in other apps) than to be lax now and try and add strictness later. So I'd say, let's go with the ISO-3166 for everything. Alex. On 10/08/06, Ilya Okomin wrote: > On 8/10/06, Spark Shen wrote: > > > 2006/8/10, Richard Liang : > > > > > > > > > > > > Spark Shen wrote: > > > > Hi All: > > > > Construct a locale like this: > > > > Locale l = new Locale("", "CD"); > > > > On RI, l.getDisplayCountry() will return "The Democratic Republic Of > > > > Congo", > > > > which is different from ISO 3166-1 standard. > > > > ("CONGO, THE DEMOCRATIC REPUBLIC OF THE" or "Congo, the Democratic > > > > Republic > > > > of the") > > > IMHO, we may follow the Java Specification, that is, ISO-3166. Do you > > > think user applications would be broken because of the difference with > > RI. > > > > > > I am not sure. But this may be a risk. > > > To follow ISO-3166 standard mentioned in the spec sounds better and > logical but...if you take a look on other several words country names you > can find that they are not the same on RI than in the ISO-3166. E.g.: > > new Locale("", "KP"); > ISO-3166 expected value: "Korea, Democratic People's Republic of " > RI returns: "North Korea" > > new Locale("", "MK"); > ISO-3166 expected value: "Macedonia, the former Yugoslav Republic of " > RI returns: "Macedonia" > > ..and so on. > > IMO in this case to be compatible with RI we can use "The Democratic > Republic Of Congo" for "CD" country. To follow completely the ISO-3166 > standard we have to make changes not only for "CD" country. > > Thanks, > Ilya. > > > > Best regards > > > > Richard. > > > > > > > > Mean while, on harmony, we do not have a country "CD"->"CONGO, THE > > > > DEMOCRATIC REPUBLIC OF THE" data item or a > > > > "CD"->" Congo, the Democratic Republic of > > > > the< http://en.wikipedia.org/wiki/Democratic_Republic_of_the_Congo>" > > > > data item at all. > > > > > > > > This test case will fail on Harmony since the returned displayCountry > > is > > > > "CD". > > > > public void test_getDisplayCountry() { > > > > > > > > Locale l_countryCD = new Locale("", "CD"); > > > > assertEquals("CONGO, THE DEMOCRATIC REPUBLIC OF THE", > > > > l_countryCD.getDisplayCountry()); > > > > } > > > > > > > > I need to add a mapping into harmony locale data. But which? > > > > > > > > "CD"->"CONGO, THE DEMOCRATIC REPUBLIC OF THE" > > > > or > > > > "CD"->"Congo, the Democratic Republic of the" > > > > or > > > > "CD"->"The Democratic Republic Of Congo" (RI) > > > > > > > > Personally, I prefer RI, since there may be applications relies on the > > > > > > returned displayCountry value. Your opinions? > > > > > > > > Best regards > > > > > > > > > > -- > > > Richard Liang > > > China Software Development Lab, IBM > > > > > > > > > > > > --------------------------------------------------------------------- > > > Terms of use : http://incubator.apache.org/harmony/mailing.html > > > To unsubscribe, e-mail: harmony-dev-unsubscribe@incubator.apache.org > > > For additional commands, e-mail: harmony-dev-help@incubator.apache.org > > > > > > > > > > > > -- > > Spark Shen > > China Software Development Lab, IBM > > > > > > > -- > -- > Ilya Okomin > Intel Middleware Products Division > > --------------------------------------------------------------------- Terms of use : http://incubator.apache.org/harmony/mailing.html To unsubscribe, e-mail: harmony-dev-unsubscribe@incubator.apache.org For additional commands, e-mail: harmony-dev-help@incubator.apache.org