< prev index next >
src/java.base/share/classes/java/util/Calendar.java
Print this page
rev 47925 : 8191349: Add a new method in j.t.f.DateTimeFormatter to reflect Unicode extensions
Reviewed-by:
*** 1448,1457 ****
--- 1448,1462 ----
* a {@code GregorianCalendar} created with {@code "iso8601"} returns
* {@code "gregory"}.
*
* <p>The default values are used for locale and time zone if these
* parameters haven't been given explicitly.
+ * <p>
+ * If the locale contains the time zone with "tz"
+ * <a href="Locale.html#def_locale_extension">Unicode extension</a>,
+ * and time zone hasn't been given explicitly, time zone in the locale
+ * is used.
*
* <p>Any out of range field values are either normalized in lenient
* mode or detected as an invalid value in non-lenient mode.
*
* @return a {@code Calendar} built with parameters of this {@code
*** 1609,1618 ****
--- 1614,1627 ----
/**
* Gets a calendar using the default time zone and locale. The
* <code>Calendar</code> returned is based on the current time
* in the default time zone with the default
* {@link Locale.Category#FORMAT FORMAT} locale.
+ * <p>
+ * If the locale contains the time zone with "tz"
+ * <a href="Locale.html#def_locale_extension">Unicode extension</a>,
+ * that time zone is used instead.
*
* @return a Calendar.
*/
public static Calendar getInstance()
{
*** 1636,1645 ****
--- 1645,1658 ----
/**
* Gets a calendar using the default time zone and specified locale.
* The <code>Calendar</code> returned is based on the current time
* in the default time zone with the given locale.
+ * <p>
+ * If the locale contains the time zone with "tz"
+ * <a href="Locale.html#def_locale_extension">Unicode extension</a>,
+ * that time zone is used instead.
*
* @param aLocale the locale for the week data
* @return a Calendar.
*/
public static Calendar getInstance(Locale aLocale)
< prev index next >