Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4640234

Some TimeZone display names haven't been localized.

    Details

    • Subcomponent:
    • Resolved In Build:
      b45
    • CPU:
      generic
    • OS:
      generic

      Description

      Some TimeZone display names haven't been localized.

      -------------------------------------------------------------------------------
      import java.text.*;
      import java.util.*;

      public class MissingL10nedName {

          public static void main(String[] args) {
              SimpleDateFormat sdf_en = new SimpleDateFormat("zzzz", Locale.US);
              SimpleDateFormat sdf_fr = new SimpleDateFormat("zzzz", Locale.FRANCE);
              SimpleDateFormat sdf_de = new SimpleDateFormat("zzzz", Locale.GERMANY);

              TimeZone tz = TimeZone.getTimeZone("Europe/Paris");
              System.out.println("Time zone display names for Europe/Paris");
              sdf_en.setTimeZone(tz);
              sdf_fr.setTimeZone(tz);
              sdf_de.setTimeZone(tz);
              System.out.println("en: " + sdf_en.format(new Date()));
              System.out.println("fr: " + sdf_fr.format(new Date()));
              System.out.println("de: " + sdf_de.format(new Date()) + "\n");

              tz = TimeZone.getTimeZone("Europe/Vatican");
              System.out.println("Time zone display names for Europe/Vatican");
              sdf_en.setTimeZone(tz);
              sdf_fr.setTimeZone(tz);
              sdf_de.setTimeZone(tz);
              System.out.println("en: " + sdf_en.format(new Date()));
              System.out.println("fr: " + sdf_fr.format(new Date()));
              System.out.println("de: " + sdf_de.format(new Date()) + "\n");

              tz = TimeZone.getTimeZone("Europe/Helsinki");
              System.out.println("Time zone display names for Europe/Helsinki");
              sdf_en.setTimeZone(tz);
              sdf_fr.setTimeZone(tz);
              sdf_de.setTimeZone(tz);
              System.out.println("en: " + sdf_en.format(new Date()));
              System.out.println("fr: " + sdf_fr.format(new Date()));
              System.out.println("de: " + sdf_de.format(new Date()) + "\n");

              tz = TimeZone.getTimeZone("Europe/Nicosia");
              System.out.println("Time zone display names for Europe/Nicosia");
              sdf_en.setTimeZone(tz);
              sdf_fr.setTimeZone(tz);
              sdf_de.setTimeZone(tz);
              System.out.println("en: " + sdf_en.format(new Date()));
              System.out.println("fr: " + sdf_fr.format(new Date()));
              System.out.println("de: " + sdf_de.format(new Date()) + "\n");
          }
      }
      -------------------------------------------------------------------------------

      Output of the above program:

      Time zone display names for Europe/Paris
      en: Central European Time
      fr: Heure d'Europe centrale
      de: Zenraleuropische Zeit

      Time zone display names for Europe/Vatican
      en: Central European Time
      fr: Central European Time
      de: Central European Time

      Time zone display names for Europe/Helsinki
      en: Eastern European Time
      fr: Heure d'Europe de l'Est
      de: Osteuropische Zeit

      Time zone display names for Europe/Nicosia
      en: Eastern European Time
      fr: Eastern European Time
      de: Eastern European Time

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                jtusla Jiri Tusla (Inactive)
                Reporter:
                peytoia Yuka Kamiya (Inactive)
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Imported:
                  Indexed: