-
getLocalizedDateTimePattern
public static String getLocalizedDateTimePattern(FormatStyle dateStyle,
FormatStyle timeStyle,
Chronology chrono,
Locale locale)
Gets the formatting pattern for date and time styles for a locale and chronology. The locale and chronology are used to lookup the locale specific format for the requested dateStyle and/or timeStyle.
If the locale contains the "rg" (region override) Unicode extensions , the formatting pattern is overridden with the one appropriate for the region.
-
Parameters:
-
dateStyle - the FormatStyle for the date, null for time-only pattern
-
timeStyle - the FormatStyle for the time, null for date-only pattern
-
chrono - the Chronology, non-null
-
locale - the locale, non-null
-
Returns:
- the locale and Chronology specific formatting pattern
-
Throws:
-
IllegalArgumentException - if both dateStyle and timeStyle are null
|
-
getLocalizedDateTimePattern
public static String getLocalizedDateTimePattern(FormatStyle dateStyle,
FormatStyle timeStyle,
Chronology chrono,
Locale locale)
Gets the formatting pattern for date and time styles for a locale and chronology. The locale and chronology are used to lookup the locale specific format for the requested dateStyle and/or timeStyle.
-
Parameters:
-
dateStyle - the FormatStyle for the date, null for time-only pattern
-
timeStyle - the FormatStyle for the time, null for date-only pattern
-
chrono - the Chronology, non-null
-
locale - the locale, non-null
-
Returns:
- the locale and Chronology specific formatting pattern
-
Throws:
-
IllegalArgumentException - if both dateStyle and timeStyle are null
|
-
getLocalizedDateTimePattern
public static String getLocalizedDateTimePattern(FormatStyle dateStyle,
FormatStyle timeStyle,
Chronology chrono,
Locale locale)
Gets the formatting pattern for date and time styles for a locale and chronology. The locale and chronology are used to lookup the locale specific format for the requested dateStyle and/or timeStyle. If the locale contains the "rg" (region override) Unicode extensions , the formatting pattern is overridden with the one appropriate for the region.
-
Parameters:
-
dateStyle - the FormatStyle for the date, null for time-only pattern
-
timeStyle - the FormatStyle for the time, null for date-only pattern
-
chrono - the Chronology, non-null
-
locale - the locale, non-null
-
Returns:
- the locale and Chronology specific formatting pattern
-
Throws:
-
IllegalArgumentException - if both dateStyle and timeStyle are null
|
|