| java.lang.Object com.ibm.icu.text.DateFormatSymbols
All known Subclasses: com.ibm.icu.text.ChineseDateFormatSymbols,
DateFormatSymbols | public class DateFormatSymbols implements Serializable,Cloneable(Code) | | DateFormatSymbols is a public class for encapsulating
localizable date-time formatting data, such as the names of the
months, the names of the days of the week, and the time zone data.
DateFormat and SimpleDateFormat both use
DateFormatSymbols to encapsulate this information.
Typically you shouldn't use DateFormatSymbols directly.
Rather, you are encouraged to create a date-time formatter with the
DateFormat class's factory methods: getTimeInstance ,
getDateInstance , or getDateTimeInstance .
These methods automatically create a DateFormatSymbols for
the formatter so that you don't have to. After the
formatter is created, you may modify its format pattern using the
setPattern method. For more information about
creating formatters using DateFormat 's factory methods,
see
DateFormat .
If you decide to create a date-time formatter with a specific
format pattern for a specific locale, you can do so with:
new SimpleDateFormat(aPattern, new DateFormatSymbols(aLocale)).
DateFormatSymbols objects are clonable. When you obtain
a DateFormatSymbols object, feel free to modify the
date-time formatting data. For instance, you can replace the localized
date-time format pattern characters with the ones that you feel easy
to remember. Or you can change the representative cities
to your favorite ones.
New DateFormatSymbols subclasses may be added to support
SimpleDateFormat for date-time formatting for additional locales.
See Also: DateFormat See Also: SimpleDateFormat See Also: com.ibm.icu.util.SimpleTimeZone author: Chen-Lieh Huang |
Inner Class :class ZoneItem | |
Constructor Summary | |
public | DateFormatSymbols() Construct a DateFormatSymbols object by loading format data from
resources for the default locale. | public | DateFormatSymbols(Locale locale) Construct a DateFormatSymbols object by loading format data from
resources for the given locale. | public | DateFormatSymbols(ULocale locale) Construct a DateFormatSymbols object by loading format data from
resources for the given ulocale. | public | DateFormatSymbols(Calendar cal, Locale locale) Get the
DateFormatSymbols object that should be used to format a
calendar system's dates in the given locale.
Subclassing:
When creating a new Calendar subclass, you must create the
ResourceBundle ResourceBundle containing its
DateFormatSymbols DateFormatSymbols in a specific place.
The resource bundle name is based on the calendar's fully-specified
class name, with ".resources" inserted at the end of the package name
(just before the class name) and "Symbols" appended to the end.
For example, the bundle corresponding to "com.ibm.icu.util.HebrewCalendar"
is "com.ibm.icu.impl.data.HebrewCalendarSymbols".
Within the ResourceBundle, this method searches for five keys:
- DayNames -
An array of strings corresponding to each possible
value of the
DAY_OF_WEEK field. | public | DateFormatSymbols(Calendar cal, ULocale locale) Get the
DateFormatSymbols object that should be used to format a
calendar system's dates in the given locale.
Subclassing:
When creating a new Calendar subclass, you must create the
ResourceBundle ResourceBundle containing its
DateFormatSymbols DateFormatSymbols in a specific place.
The resource bundle name is based on the calendar's fully-specified
class name, with ".resources" inserted at the end of the package name
(just before the class name) and "Symbols" appended to the end.
For example, the bundle corresponding to "com.ibm.icu.util.HebrewCalendar"
is "com.ibm.icu.impl.data.HebrewCalendarSymbols".
Within the ResourceBundle, this method searches for five keys:
- DayNames -
An array of strings corresponding to each possible
value of the
DAY_OF_WEEK field. | public | DateFormatSymbols(Class calendarClass, Locale locale) Variant of DateFormatSymbols(Calendar, Locale) that takes the Calendar class
instead of a Calandar instance. | public | DateFormatSymbols(Class calendarClass, ULocale locale) Variant of DateFormatSymbols(Calendar, ULocale) that takes the Calendar class
instead of a Calandar instance. | public | DateFormatSymbols(ResourceBundle bundle, Locale locale) Fetch a custom calendar's DateFormatSymbols out of the given resource
bundle. | public | DateFormatSymbols(ResourceBundle bundle, ULocale locale) Fetch a custom calendar's DateFormatSymbols out of the given resource
bundle. |
Method Summary | |
public Object | clone() | public boolean | equals(Object obj) | ZoneItem | findZoneIDTypeValue(String text, int start) Package private: used by SimpleDateformat
Gets the ZoneItem instance which has zone strings
which matches the specified text. | public String[] | getAmPmStrings() Gets ampm strings. | public static ResourceBundle | getDateFormatBundle(Class calendarClass, Locale locale) Find the ResourceBundle containing the date format information for
a specified calendar subclass in a given locale. | public static ResourceBundle | getDateFormatBundle(Class calendarClass, ULocale locale) Find the ResourceBundle containing the date format information for
a specified calendar subclass in a given locale. | public static ResourceBundle | getDateFormatBundle(Calendar cal, Locale locale) Variant of getDateFormatBundle(java.lang.Class, java.util.Locale) that takes
a Calendar instance instead of a Calendar class. | public static ResourceBundle | getDateFormatBundle(Calendar cal, ULocale locale) Variant of getDateFormatBundle(java.lang.Class, java.util.Locale) that takes
a Calendar instance instead of a Calendar class. | public String[] | getEraNames() Gets era name strings. | public String[] | getEras() Gets era strings. | public String | getLocalPatternChars() Gets localized date-time pattern characters. | final public ULocale | getLocale(ULocale.Type type) Return the locale that was used to create this object, or null.
This may may differ from the locale requested at the time of
this object's creation. | public String[] | getMonths() Gets month strings. | public String[] | getMonths(int context, int width) Gets month strings. | public String[] | getQuarters(int context, int width) Gets quarter strings. | public String[] | getShortMonths() Gets short month strings. | public String[] | getShortWeekdays() Gets short weekday strings. | public String[] | getWeekdays() Gets weekday strings. | public String[] | getWeekdays(int context, int width) Gets weekday strings. | final int | getZoneIndex(String ID) Package private: used by SimpleDateFormat
Gets the index for the given time zone ID to obtain the timezone
strings for formatting. | String | getZoneString(String zid, int type) Package private: used by SimpleDateFormat. | public String[][] | getZoneStrings() Gets timezone strings. | public int | hashCode() Override hashCode. | protected void | initializeData(ULocale desiredLocale, String type) | protected void | initializeData(ULocale desiredLocale, CalendarData calData) | public void | setAmPmStrings(String[] newAmpms) Sets ampm strings. | public void | setEraNames(String[] newEraNames) Sets era name strings. | public void | setEras(String[] newEras) Sets era strings. | public void | setLocalPatternChars(String newLocalPatternChars) Sets localized date-time pattern characters. | final void | setLocale(ULocale valid, ULocale actual) Set information about the locales that were used to create this
object. | public void | setMonths(String[] newMonths) Sets month strings. | public void | setMonths(String[] newMonths, int context, int width) Sets month strings. | public void | setQuarters(String[] newQuarters, int context, int width) Sets quarter strings. | public void | setShortMonths(String[] newShortMonths) Sets short month strings. | public void | setShortWeekdays(String[] newShortWeekdays) Sets short weekday strings. | public void | setWeekdays(String[] newWeekdays, int context, int width) Sets weekday strings. | public void | setWeekdays(String[] newWeekdays) Sets weekday strings. | public void | setZoneStrings(String[][] newZoneStrings) Sets timezone strings. |
ABBREVIATED | final public static int ABBREVIATED(Code) | | Constant for width.
|
DT_CONTEXT_COUNT | final public static int DT_CONTEXT_COUNT(Code) | | Constant for context.
|
DT_WIDTH_COUNT | final public static int DT_WIDTH_COUNT(Code) | | Constant for width.
|
FORMAT | final public static int FORMAT(Code) | | Constant for context.
|
NARROW | final public static int NARROW(Code) | | Constant for width.
|
STANDALONE | final public static int STANDALONE(Code) | | Constant for context.
|
TIMEZONE_SHORT_GENERICTIMEZONE_SHORT_STANDARDTIMEZONE_SHORT_DAYLIGHTTIMEZONE_LONG_GENERICTIMEZONE_LONG_STANDARDTIMEZONE_LONG_DAYLIGHTTIMEZONE_EXEMPLAR_CITYTIMEZONE_COUNT | final static int TIMEZONE_SHORT_GENERICTIMEZONE_SHORT_STANDARDTIMEZONE_SHORT_DAYLIGHTTIMEZONE_LONG_GENERICTIMEZONE_LONG_STANDARDTIMEZONE_LONG_DAYLIGHTTIMEZONE_EXEMPLAR_CITYTIMEZONE_COUNT(Code) | | The translation type of the translated zone strings
|
WIDE | final public static int WIDE(Code) | | Constant for width.
|
ampms | String ampms(Code) | | AM and PM strings. For example: "AM" and "PM". An array of
2 strings, indexed by Calendar.AM and
Calendar.PM .
|
eraNames | String eraNames(Code) | | Era name strings. For example: "Anno Domini" and "Before Christ". An array of 2 strings,
indexed by Calendar.BC and Calendar.AD .
|
eras | String eras(Code) | | Era strings. For example: "AD" and "BC". An array of 2 strings,
indexed by Calendar.BC and Calendar.AD .
|
localPatternChars | String localPatternChars(Code) | | Localized date-time pattern characters. For example, a locale may
wish to use 'u' rather than 'y' to represent years in its date format
pattern strings.
This string must be exactly 18 characters long, with the index of
the characters described by DateFormat.ERA_FIELD ,
DateFormat.YEAR_FIELD , etc. Thus, if the string were
"Xz...", then localized patterns would use 'X' for era and 'z' for year.
|
millisPerHour | final static int millisPerHour(Code) | | Useful constant for defining timezone offsets.
|
months | String months(Code) | | Month strings. For example: "January", "February", etc. An array
of 13 strings (some calendars have 13 months), indexed by
Calendar.JANUARY , Calendar.FEBRUARY , etc.
|
narrowEras | String narrowEras(Code) | | Narrow era names. For example: "A" and "B". An array of 2 strings,
indexed by Calendar.BC and Calendar.AD .
|
narrowMonths | String narrowMonths(Code) | | Narrow month strings. For example: "J", "F", etc. An array of
13 strings (some calendars have 13 months), indexed by
Calendar.JANUARY , Calendar.FEBRUARY , etc.
|
narrowWeekdays | String narrowWeekdays(Code) | | Narrow weekday strings. For example: "S", "M", etc. An array
of 8 strings, indexed by Calendar.SUNDAY ,
Calendar.MONDAY , etc.
The element narrowWeekdays[0] is ignored.
|
patternChars | final static String patternChars(Code) | | Unlocalized date-time pattern characters. For example: 'y', 'd', etc.
All locales use the same unlocalized pattern characters.
|
quarters | String quarters(Code) | | Full quarter names. For example: "1st Quarter", "2nd Quarter", "3rd Quarter",
"4th Quarter". An array of 4 strings, indexed by the month divided by 3.
|
shortMonths | String shortMonths(Code) | | Short month strings. For example: "Jan", "Feb", etc. An array of
13 strings (some calendars have 13 months), indexed by
Calendar.JANUARY , Calendar.FEBRUARY , etc.
|
shortQuarters | String shortQuarters(Code) | | Abbreviated quarter names. For example: "Q1", "Q2", "Q3", "Q4". An array
of 4 strings indexed by the month divided by 3.
|
shortWeekdays | String shortWeekdays(Code) | | Short weekday strings. For example: "Sun", "Mon", etc. An array
of 8 strings, indexed by Calendar.SUNDAY ,
Calendar.MONDAY , etc.
The element shortWeekdays[0] is ignored.
|
standaloneMonths | String standaloneMonths(Code) | | Standalone month strings. For example: "January", "February", etc. An array
of 13 strings (some calendars have 13 months), indexed by
Calendar.JANUARY , Calendar.FEBRUARY , etc.
|
standaloneNarrowMonths | String standaloneNarrowMonths(Code) | | Standalone narrow month strings. For example: "J", "F", etc. An array of
13 strings (some calendars have 13 months), indexed by
Calendar.JANUARY , Calendar.FEBRUARY , etc.
|
standaloneNarrowWeekdays | String standaloneNarrowWeekdays(Code) | | Standalone narrow weekday strings. For example: "S", "M", etc. An array
of 8 strings, indexed by Calendar.SUNDAY ,
Calendar.MONDAY , etc.
The element standaloneNarrowWeekdays[0] is ignored.
|
standaloneQuarters | String standaloneQuarters(Code) | | Standalone full quarter names. For example: "1st Quarter", "2nd Quarter", "3rd Quarter",
"4th Quarter". An array of 4 strings, indexed by the month divided by 3.
|
standaloneShortMonths | String standaloneShortMonths(Code) | | Standalone short month strings. For example: "Jan", "Feb", etc. An array of
13 strings (some calendars have 13 months), indexed by
Calendar.JANUARY , Calendar.FEBRUARY , etc.
|
standaloneShortQuarters | String standaloneShortQuarters(Code) | | Standalone abbreviated quarter names. For example: "Q1", "Q2", "Q3", "Q4". An array
of 4 strings indexed by the month divided by 3.
|
standaloneShortWeekdays | String standaloneShortWeekdays(Code) | | Standalone short weekday strings. For example: "Sun", "Mon", etc. An array
of 8 strings, indexed by Calendar.SUNDAY ,
Calendar.MONDAY , etc.
The element standaloneShortWeekdays[0] is ignored.
|
standaloneWeekdays | String standaloneWeekdays(Code) | | Standalone weekday strings. For example: "Sunday", "Monday", etc. An array
of 8 strings, indexed by Calendar.SUNDAY ,
Calendar.MONDAY , etc.
The element standaloneWeekdays[0] is ignored.
|
weekdays | String weekdays(Code) | | Weekday strings. For example: "Sunday", "Monday", etc. An array
of 8 strings, indexed by Calendar.SUNDAY ,
Calendar.MONDAY , etc.
The element weekdays[0] is ignored.
|
DateFormatSymbols | public DateFormatSymbols()(Code) | | Construct a DateFormatSymbols object by loading format data from
resources for the default locale.
throws: java.util.MissingResourceException - if the resources for the default locale cannot befound or cannot be loaded. |
DateFormatSymbols | public DateFormatSymbols(Locale locale)(Code) | | Construct a DateFormatSymbols object by loading format data from
resources for the given locale.
throws: java.util.MissingResourceException - if the resources for the specified locale cannot befound or cannot be loaded. |
DateFormatSymbols | public DateFormatSymbols(ULocale locale)(Code) | | Construct a DateFormatSymbols object by loading format data from
resources for the given ulocale.
throws: java.util.MissingResourceException - if the resources for the specified locale cannot befound or cannot be loaded. |
DateFormatSymbols | public DateFormatSymbols(Calendar cal, Locale locale)(Code) | | Get the
DateFormatSymbols object that should be used to format a
calendar system's dates in the given locale.
Subclassing:
When creating a new Calendar subclass, you must create the
ResourceBundle ResourceBundle containing its
DateFormatSymbols DateFormatSymbols in a specific place.
The resource bundle name is based on the calendar's fully-specified
class name, with ".resources" inserted at the end of the package name
(just before the class name) and "Symbols" appended to the end.
For example, the bundle corresponding to "com.ibm.icu.util.HebrewCalendar"
is "com.ibm.icu.impl.data.HebrewCalendarSymbols".
Within the ResourceBundle, this method searches for five keys:
- DayNames -
An array of strings corresponding to each possible
value of the
DAY_OF_WEEK field. Even though
DAY_OF_WEEK starts with SUNDAY = 1,
This array is 0-based; the name for Sunday goes in the
first position, at index 0. If this key is not found
in the bundle, the day names are inherited from the
default DateFormatSymbols for the requested locale.
- DayAbbreviations -
An array of abbreviated day names corresponding
to the values in the "DayNames" array. If this key
is not found in the resource bundle, the "DayNames"
values are used instead. If neither key is found,
the day abbreviations are inherited from the default
DateFormatSymbols for the locale.
- MonthNames -
An array of strings corresponding to each possible
value of the
MONTH field. If this key is not found
in the bundle, the month names are inherited from the
default DateFormatSymbols for the requested locale.
- MonthAbbreviations -
An array of abbreviated day names corresponding
to the values in the "MonthNames" array. If this key
is not found in the resource bundle, the "MonthNames"
values are used instead. If neither key is found,
the day abbreviations are inherited from the default
DateFormatSymbols for the locale.
- Eras -
An array of strings corresponding to each possible
value of the
ERA field. If this key is not found
in the bundle, the era names are inherited from the
default DateFormatSymbols for the requested locale.
Parameters: cal - The calendar system whose date format symbols are desired. Parameters: locale - The locale whose symbols are desired. See Also: DateFormatSymbols.DateFormatSymbols(java.util.Locale) |
DateFormatSymbols | public DateFormatSymbols(Calendar cal, ULocale locale)(Code) | | Get the
DateFormatSymbols object that should be used to format a
calendar system's dates in the given locale.
Subclassing:
When creating a new Calendar subclass, you must create the
ResourceBundle ResourceBundle containing its
DateFormatSymbols DateFormatSymbols in a specific place.
The resource bundle name is based on the calendar's fully-specified
class name, with ".resources" inserted at the end of the package name
(just before the class name) and "Symbols" appended to the end.
For example, the bundle corresponding to "com.ibm.icu.util.HebrewCalendar"
is "com.ibm.icu.impl.data.HebrewCalendarSymbols".
Within the ResourceBundle, this method searches for five keys:
- DayNames -
An array of strings corresponding to each possible
value of the
DAY_OF_WEEK field. Even though
DAY_OF_WEEK starts with SUNDAY = 1,
This array is 0-based; the name for Sunday goes in the
first position, at index 0. If this key is not found
in the bundle, the day names are inherited from the
default DateFormatSymbols for the requested locale.
- DayAbbreviations -
An array of abbreviated day names corresponding
to the values in the "DayNames" array. If this key
is not found in the resource bundle, the "DayNames"
values are used instead. If neither key is found,
the day abbreviations are inherited from the default
DateFormatSymbols for the locale.
- MonthNames -
An array of strings corresponding to each possible
value of the
MONTH field. If this key is not found
in the bundle, the month names are inherited from the
default DateFormatSymbols for the requested locale.
- MonthAbbreviations -
An array of abbreviated day names corresponding
to the values in the "MonthNames" array. If this key
is not found in the resource bundle, the "MonthNames"
values are used instead. If neither key is found,
the day abbreviations are inherited from the default
DateFormatSymbols for the locale.
- Eras -
An array of strings corresponding to each possible
value of the
ERA field. If this key is not found
in the bundle, the era names are inherited from the
default DateFormatSymbols for the requested locale.
Parameters: cal - The calendar system whose date format symbols are desired. Parameters: locale - The ulocale whose symbols are desired. See Also: DateFormatSymbols.DateFormatSymbols(java.util.Locale) |
DateFormatSymbols | public DateFormatSymbols(ResourceBundle bundle, Locale locale)(Code) | | Fetch a custom calendar's DateFormatSymbols out of the given resource
bundle. Symbols that are not overridden are inherited from the
default DateFormatSymbols for the locale.
See Also: DateFormatSymbols.DateFormatSymbols |
equals | public boolean equals(Object obj)(Code) | | Override equals
|
findZoneIDTypeValue | ZoneItem findZoneIDTypeValue(String text, int start)(Code) | | Package private: used by SimpleDateformat
Gets the ZoneItem instance which has zone strings
which matches the specified text.
Parameters: text - The text which contains a zone string Parameters: start - The start position of zone string in the text A ZonItem instance for the longest matching zonestring. |
getAmPmStrings | public String[] getAmPmStrings()(Code) | | Gets ampm strings. For example: "AM" and "PM".
the weekday strings. |
getDateFormatBundle | public static ResourceBundle getDateFormatBundle(Class calendarClass, Locale locale) throws MissingResourceException(Code) | | Find the ResourceBundle containing the date format information for
a specified calendar subclass in a given locale.
The resource bundle name is based on the calendar's fully-specified
class name, with ".resources" inserted at the end of the package name
(just before the class name) and "Symbols" appended to the end.
For example, the bundle corresponding to "com.ibm.icu.util.HebrewCalendar"
is "com.ibm.icu.impl.data.HebrewCalendarSymbols".
|
getDateFormatBundle | public static ResourceBundle getDateFormatBundle(Class calendarClass, ULocale locale) throws MissingResourceException(Code) | | Find the ResourceBundle containing the date format information for
a specified calendar subclass in a given locale.
The resource bundle name is based on the calendar's fully-specified
class name, with ".resources" inserted at the end of the package name
(just before the class name) and "Symbols" appended to the end.
For example, the bundle corresponding to "com.ibm.icu.util.HebrewCalendar"
is "com.ibm.icu.impl.data.HebrewCalendarSymbols".
|
getEraNames | public String[] getEraNames()(Code) | | Gets era name strings. For example: "Anno Domini" and "Before Christ".
the era strings. |
getEras | public String[] getEras()(Code) | | Gets era strings. For example: "AD" and "BC".
the era strings. |
getLocalPatternChars | public String getLocalPatternChars()(Code) | | Gets localized date-time pattern characters. For example: 'u', 't', etc.
the localized date-time pattern characters. |
getMonths | public String[] getMonths()(Code) | | Gets month strings. For example: "January", "February", etc.
the month strings. |
getMonths | public String[] getMonths(int context, int width)(Code) | | Gets month strings. For example: "January", "February", etc.
Parameters: context - The month context, FORMAT or STANDALONE. Parameters: width - The width or the returned month string,either WIDE, ABBREVIATED, or NARROW. the month strings. |
getQuarters | public String[] getQuarters(int context, int width)(Code) | | Gets quarter strings. For example: "1st Quarter", "2nd Quarter", etc.
Parameters: context - The quarter context, FORMAT or STANDALONE. Parameters: width - The width or the returned quarter string,either WIDE or ABBREVIATED. There are no NARROW quarters. the quarter strings. |
getShortMonths | public String[] getShortMonths()(Code) | | Gets short month strings. For example: "Jan", "Feb", etc.
the short month strings. |
getShortWeekdays | public String[] getShortWeekdays()(Code) | | Gets short weekday strings. For example: "Sun", "Mon", etc.
the short weekday strings. Use Calendar.SUNDAY ,Calendar.MONDAY , etc. to index the result array. |
getWeekdays | public String[] getWeekdays()(Code) | | Gets weekday strings. For example: "Sunday", "Monday", etc.
the weekday strings. Use Calendar.SUNDAY ,Calendar.MONDAY , etc. to index the result array. |
getWeekdays | public String[] getWeekdays(int context, int width)(Code) | | Gets weekday strings. For example: "Sunday", "Monday", etc.
the weekday strings. Use Calendar.SUNDAY ,Calendar.MONDAY , etc. to index the result array. Parameters: context - Formatting context, either FORMAT or STANDALONE. Parameters: width - Width of strings to be returned, eitherWIDE, ABBREVIATED, or NARROW |
getZoneIndex | final int getZoneIndex(String ID)(Code) | | Package private: used by SimpleDateFormat
Gets the index for the given time zone ID to obtain the timezone
strings for formatting. The time zone ID is just for programmatic
lookup. NOT LOCALIZED!!!
Parameters: ID - the given time zone ID. the index of the given time zone ID. Returns -1 ifthe given time zone ID can't be located in the DateFormatSymbols object. See Also: com.ibm.icu.util.SimpleTimeZone |
getZoneString | String getZoneString(String zid, int type)(Code) | | Package private: used by SimpleDateFormat.
Gets the string for the specified time zone.
Parameters: zid - The time zone ID Parameters: type - The type of zone string The zone string, or null if not available. |
getZoneStrings | public String[][] getZoneStrings()(Code) | | Gets timezone strings.
the timezone strings. |
hashCode | public int hashCode()(Code) | | Override hashCode.
Generates a hash code for the DateFormatSymbols object.
|
initializeData | protected void initializeData(ULocale desiredLocale, String type)(Code) | | Parameters: desiredLocale - Parameters: type - |
initializeData | protected void initializeData(ULocale desiredLocale, CalendarData calData)(Code) | | Parameters: desiredLocale - Parameters: calData - |
setAmPmStrings | public void setAmPmStrings(String[] newAmpms)(Code) | | Sets ampm strings. For example: "AM" and "PM".
Parameters: newAmpms - the new ampm strings. |
setEraNames | public void setEraNames(String[] newEraNames)(Code) | | Sets era name strings. For example: "Anno Domini" and "Before Christ".
Parameters: newEraNames - the new era strings. |
setEras | public void setEras(String[] newEras)(Code) | | Sets era strings. For example: "AD" and "BC".
Parameters: newEras - the new era strings. |
setLocalPatternChars | public void setLocalPatternChars(String newLocalPatternChars)(Code) | | Sets localized date-time pattern characters. For example: 'u', 't', etc.
Parameters: newLocalPatternChars - the new localized date-timepattern characters. |
setLocale | final void setLocale(ULocale valid, ULocale actual)(Code) | | Set information about the locales that were used to create this
object. If the object was not constructed from locale data,
both arguments should be set to null. Otherwise, neither
should be null. The actual locale must be at the same level or
less specific than the valid locale. This method is intended
for use by factories or other entities that create objects of
this class.
Parameters: valid - the most specific locale containing any resourcedata, or null Parameters: actual - the locale containing data used to construct thisobject, or null See Also: com.ibm.icu.util.ULocale See Also: com.ibm.icu.util.ULocale.VALID_LOCALE See Also: com.ibm.icu.util.ULocale.ACTUAL_LOCALE |
setMonths | public void setMonths(String[] newMonths)(Code) | | Sets month strings. For example: "January", "February", etc.
Parameters: newMonths - the new month strings. |
setMonths | public void setMonths(String[] newMonths, int context, int width)(Code) | | Sets month strings. For example: "January", "February", etc.
Parameters: newMonths - the new month strings. Parameters: context - The formatting context, FORMAT or STANDALONE. Parameters: width - The width of the month string,either WIDE, ABBREVIATED, or NARROW. |
setQuarters | public void setQuarters(String[] newQuarters, int context, int width)(Code) | | Sets quarter strings. For example: "1st Quarter", "2nd Quarter", etc.
Parameters: newQuarters - the new quarter strings. Parameters: context - The formatting context, FORMAT or STANDALONE. Parameters: width - The width of the quarter string,either WIDE or ABBREVIATED. There are no NARROW quarters. |
setShortMonths | public void setShortMonths(String[] newShortMonths)(Code) | | Sets short month strings. For example: "Jan", "Feb", etc.
Parameters: newShortMonths - the new short month strings. |
setShortWeekdays | public void setShortWeekdays(String[] newShortWeekdays)(Code) | | Sets short weekday strings. For example: "Sun", "Mon", etc.
Parameters: newShortWeekdays - the new short weekday strings. The array shouldbe indexed by Calendar.SUNDAY ,Calendar.MONDAY , etc. |
setWeekdays | public void setWeekdays(String[] newWeekdays, int context, int width)(Code) | | Sets weekday strings. For example: "Sunday", "Monday", etc.
Parameters: newWeekdays - The new weekday strings. Parameters: context - The formatting context, FORMAT or STANDALONE. Parameters: width - The width of the strings,either WIDE, ABBREVIATED, or NARROW. |
setWeekdays | public void setWeekdays(String[] newWeekdays)(Code) | | Sets weekday strings. For example: "Sunday", "Monday", etc.
Parameters: newWeekdays - the new weekday strings. The array shouldbe indexed by Calendar.SUNDAY ,Calendar.MONDAY , etc. |
setZoneStrings | public void setZoneStrings(String[][] newZoneStrings)(Code) | | Sets timezone strings.
Parameters: newZoneStrings - the new timezone strings. |
|
|