+
+ /**
+ * @return Description of time part of timestamp in locale-specific format
+ */
+ public String getTimeText()
+ {
+ if (_timeText == null)
+ {
+ if (_valid) {
+ _timeText = format(DEFAULT_TIME_FORMAT);
+ }
+ else _timeText = "";
+ }
+ return _timeText;
+ }
+
+ /**
+ * Utility method for formatting dates / times
+ * @param inFormat formatter object
+ * @return formatted String
+ */
+ private String format(DateFormat inFormat)
+ {
+ CALENDAR.setTimeInMillis(_seconds * 1000L);
+ return inFormat.format(CALENDAR.getTime());
+ }
+
+ /**
+ * @return a Calendar object representing this timestamp
+ */
+ public Calendar getCalendar()
+ {
+ Calendar cal = Calendar.getInstance();
+ cal.setTimeInMillis(_seconds * 1000L);
+ return cal;
+ }