|
Oracle® Database Globalization Development Kit Java API Reference 10g Release 2 (10.2) Part No. B14224-02 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
|
+--java.text.Format
|
+--oracle.i18n.text.OraDateFormat
|
+--oracle.i18n.text.OraSimpleDateFormat
The OraSimpleDateFormat class is a concrete class to do
locale-sensitive formatting and parsing between date/time and string.
It supports Oracle date/time formatting behavior.
OraDateFormat,
Serialized Form| Nested Class Summary |
| Nested classes inherited from class java.text.Format |
Format.Field |
| Field Summary |
| Fields inherited from class oracle.i18n.text.OraDateFormat |
ALL_FIELD, AM_PM_FIELD, calendar, CENTRY_FIELD, DATE_FIELD, DAY_OF_WEEK_FIELD, DAY_OF_YEAR_FIELD, DEFAULT, ERA_FIELD, HOUR_FIELD, HOUR_OF_DAY_FIELD, ISO_WEEK_OF_YEAR_FIELD, ISO_YEAR_FIELD, JULIAN_DAY_FIELD, LONG, MILLISECOND_FIELD, MINUTE_FIELD, MONTH_FIELD, QUARTER_OF_YEAR_FIELD, SECOND_FIELD, SECONDS_FIELD, SHORT, TEXT_FIELD, TIMEZONE_FIELD, WEEK_OF_MONTH_FIELD, WEEK_OF_YEAR_FIELD, YEAR_FIELD |
| Constructor Summary | |
OraSimpleDateFormat()
Deprecated. As of Oracle Database 10g Release 2 (10.2), replaced by OraSimpleDateFormat(String, Locale) |
|
OraSimpleDateFormat(String pattern)
Deprecated. As of Oracle Database 10g Release 2 (10.2), replaced by OraSimpleDateFormat(String, Locale) |
|
OraSimpleDateFormat(String pattern,
Locale locale)
Constructs an OraSimpleDateFormat object that uses
the given format pattern for the given locale. |
|
OraSimpleDateFormat(String pattern,
oracle.i18n.text.OraDateFormatSymbols symbols)
Deprecated. As of Oracle Database 10g Release 2 (10.2), replaced by OraSimpleDateFormat(String, OraDateFormatSymbols, Locale) |
|
OraSimpleDateFormat(String pattern,
oracle.i18n.text.OraDateFormatSymbols symbols,
Locale locale)
Constructs an OraSimpleDateFormat object that uses
the given format pattern and the given Oracle date/time symbols
for the given locale. |
|
OraSimpleDateFormat(String pattern,
oracle.i18n.text.OraDateFormatSymbols symbols,
oracle.i18n.util.OraLocaleInfo localeInfo)
Constructs an OraSimpleDateFormat object that uses
the given format pattern and the given Oracle date/time symbols
for the given OraLocaleInfo object. |
|
OraSimpleDateFormat(String pattern,
oracle.i18n.util.OraLocaleInfo localeInfo)
Constructs an OraSimpleDateFormat object that uses
the given format pattern for the given OraLocaleInfo object. |
|
| Method Summary | |
void |
applyPattern(String pattern)
Applies the given format pattern of this date/time formatter. |
Object |
clone()
Overrides the clone method. |
boolean |
equals(Object object)
Overrides the equals method. |
StringBuffer |
format(Date date,
StringBuffer toAppendTo,
FieldPosition pos)
Formats a Date object into a date/time string.
|
Locale |
getLocale()
Returns the locale associated with this date/time formatter. |
oracle.i18n.text.OraDateFormatSymbols |
getOraDateFormatSymbols()
Returns the Oracle date/time format symbols or translations used in this formatter. |
int |
hashCode()
Overrides the hashCode method. |
Date |
parse(String text,
ParsePosition pos)
Parses a date/time string into a Date object,
starting from the given parse position. |
void |
setOraDateFormatSymbols(oracle.i18n.text.OraDateFormatSymbols sym)
Sets the Oracle date/time format symbols or translations to the given OraDateFormatSymbols object for this formatter. |
String |
toPattern()
Returns the format pattern associated with this date/time formatter. |
| Methods inherited from class java.text.Format |
format, formatToCharacterIterator, parseObject |
| Methods inherited from class java.lang.Object |
finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public OraSimpleDateFormat()
OraSimpleDateFormat(String, Locale)
OraSimpleDateFormat object that uses
the default date/time formatting sytle for
the default locale.
public OraSimpleDateFormat(String pattern)
throws ParseException
OraSimpleDateFormat(String, Locale)
OraSimpleDateFormat object that uses
the given format pattern for the default locale.
pattern - the given format pattern
ParseException - if the format pattern is invalid
public OraSimpleDateFormat(String pattern,
Locale locale)
throws ParseException
OraSimpleDateFormat object that uses
the given format pattern for the given locale.
pattern - the given format patternlocale - the given locale
ParseException - if the format pattern is invalid
public OraSimpleDateFormat(String pattern,
oracle.i18n.util.OraLocaleInfo localeInfo)
throws ParseException
OraSimpleDateFormat object that uses
the given format pattern for the given OraLocaleInfo object.
pattern - the given format patternlocaleInfo - the given OraLocaleInfo object
ParseException - if the format pattern is invalid
public OraSimpleDateFormat(String pattern,
oracle.i18n.text.OraDateFormatSymbols symbols)
throws ParseException
OraSimpleDateFormat(String, OraDateFormatSymbols, Locale)
OraSimpleDateFormat object that uses
the given format pattern and the given Oracle date/time symbols
for the default locale.
pattern - the given format patternsymbols - the given Oracle date/time symbols
ParseException - if the format pattern is invalid
public OraSimpleDateFormat(String pattern,
oracle.i18n.text.OraDateFormatSymbols symbols,
Locale locale)
throws ParseException
OraSimpleDateFormat object that uses
the given format pattern and the given Oracle date/time symbols
for the given locale.
pattern - the given format patternsymbols - the given Oracle date/time symbolslocale - the given locale
ParseException - if the format pattern is invalid
public OraSimpleDateFormat(String pattern,
oracle.i18n.text.OraDateFormatSymbols symbols,
oracle.i18n.util.OraLocaleInfo localeInfo)
throws ParseException
OraSimpleDateFormat object that uses
the given format pattern and the given Oracle date/time symbols
for the given OraLocaleInfo object.
pattern - the given format patternsymbols - the given Oracle date/time symbolslocaleInfo - the given OraLocaleInfo object
ParseException - if the format pattern is invalid| Method Detail |
public void applyPattern(String pattern)
throws ParseException
pattern - the given format pattern
ParseException - if the format pattern is invalid
public StringBuffer format(Date date,
StringBuffer toAppendTo,
FieldPosition pos)
Date object into a date/time string.
Sets field position if needed.
format in class OraDateFormatdate - the date/time object to be formatted.toAppendTo - the string buffer to be appended with the formatted
date/time string.pos - to be used to get offsets of a given field in the returned
string buffer. On input, the alignment field of which the
offsets are to be returned. On output, the offsets of the alignment
field in the returned string buffer.
IllegalArgumentException - if any error occurs in the format
operationpublic oracle.i18n.text.OraDateFormatSymbols getOraDateFormatSymbols()
OracleDateFormatSymbols objectOraDateFormatSymbolspublic void setOraDateFormatSymbols(oracle.i18n.text.OraDateFormatSymbols sym)
OraDateFormatSymbols object for this formatter.
sym - the given OraDateFormatSymbols object
public Date parse(String text,
ParsePosition pos)
Date object,
starting from the given parse position.
parse in class OraDateFormattext - the date/time stringpos - indicates where to start the parsing on input. On output,
returns where the parse ends if parsing succeeds, or the start
index if it fails.
Date object
IllegalArgumentException - if the format pattern associated
with this formatter is not valid for parsing or the given
date/time string cannot be parsed into a Date
objectpublic String toPattern()
public Locale getLocale()
Locale objectpublic Object clone()
clone method.
clone in class OraDateFormatpublic boolean equals(Object object)
equals method.
equals in class OraDateFormatobject - an object to be compared
true if two objects are identical, otherwise
falsepublic int hashCode()
hashCode method.
hashCode in class Object
|
Oracle® Database Globalization Development Kit Java API Reference 10g Release 2 (10.2) Part No. B14224-02 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||