<i18n dev> Review request: Splitting locale resources (FormatData) for java.time classes
naoto.sato at oracle.com
Wed Apr 3 14:09:53 PDT 2013
Looks good overall. Some minor comments:
- sun/util/locale/provider/CalendarNameProviderImpl.java, line 234:
"cldr" -> "javatime"
- sun/util/locale/provider/LocaleResources.java, line 370: Should this
method be renamed to getJavaTime...()?
- src/share/classes/sun/util/resources/LocaleData.java, line 128: Is
there any chance that this assertion would fail with FALLBACK adapter?
On 4/3/13 9:09 AM, Masayoshi Okutsu wrote:
> I've made changes for splitting locale resources into FormatData
> required by the legacy i18n classes and JavaTimeSupplementary required
> by the java.time classes. The reason of this split is to make locale
> resources maintenance easier. Changes are mostly in the locale data
> adapter side.
> Here are concrete changes in a random order:
> - Split FormatData files for JRE into the FormatData files and their
> corresponding JavaTimeSupplementary files. The supplementary data is
> added to its FormatData on demand at runtime. This is to avoid loading
> java.time specific resources in case they are not used. All
> JavaTimeSupplementary files were generated by a tool. But the tool isn't
> included in webrev. It's still a mess.
> - Changed prefix "cldr." to "java.time." for java.time specific resources.
> - "java.time.*DatePattrens" resources are now converted from legacy JRE
> resources rather than from CLDR. This change required the
> TestNonIsoFormatter.java change.
> - Added missing resources (due to a tool bug) to FormatData files.
> - No format changes to FormatData files generated from CLDR (XML).
> - Added ParallelListResourceBundle which supports additional contents
> (key-value pairs). FormatData* classes are now
> ParallelListResourceBundle subclasses. sun/util/resources/LocaleData
> takes care of adding supplementary data at runtime.
> - Renamed CalendarDataUtility.retrieveCldr* to .retrieveJavaTime*.
> - Cleaned up OpenListResourceBundle.
> - CLDR Converter Tool now takes "approved" and "contributed" data items
> because there are too many missing elements in arrays. However,
> FormatData and JavaTimeSupplementary files for JRE have only approved
> - Changed some copyright text and removed "DO NOT EDIT" comment lines. I
> don't believe those files can be re-generated using the older version of
> CLDR Converter Tool.
> There are some remaining work items.
> - Need more verification of the actual locale resources.
> - Clean up the JavaTimeSupplementary generator tool.
> - Add a test for ParallelListResourceBundl, which is almost ready for
> review, but it requires a bug ID for the @bug tag of jtreg.
> - Clean up test/sun/text/resources/LocaleData with the additional
More information about the i18n-dev