public class DBTimestamp extends AbstractTimeValue implements DBTimeTranslator
CLASS_DATE, CLASS_TIME, CLASS_TIMESTAMP
Constructor and Description |
---|
DBTimestamp(java.lang.String dbTimestamp,
java.lang.String sqlClass,
java.lang.String inFormat,
java.lang.String outFormat) |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getDSTime()
Returns this timestamp/date/time value in the directory canonical
string format (e.g.
CCYYMMDDHHMMSSNNNNNNNNN ,
CCYYMMDD or HHMMSS ) or in the
32-bit integer string format (e.g. "1013368206"),
if translation was successful. |
boolean |
precisionLost()
Indicates whether precision was lost converting this timestamp
to a directory timestamp.
|
void |
setDSTime(java.lang.String nativeTime)
Translates a database-native timestamp/date/time value into an
equivalent directory format as per the arguments passed to the constructor.
|
getErrorMessage, getExceptions, parseError
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getErrorMessage, getExceptions, parseError
public DBTimestamp(java.lang.String dbTimestamp, java.lang.String sqlClass, java.lang.String inFormat, java.lang.String outFormat)
public void setDSTime(java.lang.String nativeTime) throws java.text.ParseException
DBTimeTranslator
setDSTime
in interface DBTimeTranslator
nativeTime
- a database-native timestamp, date, or time value;
may be null
java.text.ParseException
public boolean precisionLost()
precisionLost
in interface DBTimeTranslator
true
if precision was lost;
false
otherwisepublic java.lang.String getDSTime()
DBTimeTranslator
CCYYMMDDHHMMSSNNNNNNNNN
,
CCYYMMDD
or HHMMSS
) or in the
32-bit integer string format (e.g. "1013368206"),
if translation was successful.getDSTime
in interface DBTimeTranslator
null