Creating a java application that supports different locales, but I would like to customize the display of DateFormat beyond what is available between FULL, LONG, MEDIUM and SHORT DateFormat. I would like to do such things as putting a character between the date and time components of DateFormat.getDateTimeFormat (), in lower case AM / PM, etc., At least for English.
can think of 3 ways to do this:
1) if locale is English, use my own format string for the new SimpleDateFormat object.
2) change the default format strings for existing locales
3) create a new locale option that sets the format strings that I want
Can't figure out how to make 2 or 3 (or if it's possible), and would rather not do 1 ... has anyone dealt with something like this before?
also, it seems that 2 or 3 would be necessary to reduce AM / PM? (AmPmMarkers resource specification for locale date and time settings)
java internationalization localization locale
Joe Oct 21 '08 at 20:15 2008-10-21 20:15
source share