public interface MDatetime
MDate
,
MTime
,
MTimestamp
Modifier and Type | Method and Description |
---|---|
int |
getDay()
Returns the day component from this date/time.
|
int |
getHour()
Returns the hour component from this date/time.
|
int |
getMinute()
Returns the minute component from this date/time.
|
int |
getMonth()
Returns the month component from this date/time.
|
int |
getSecond()
Returns the second component from this date/time, as an integer.
|
int |
getYear()
Returns the year component of this date/time.
|
java.util.Date |
toDate(java.util.Calendar calendar)
Returns this date/time value as a
Date using the specified
calendar. |
long |
toMilliseconds()
Returns the number of milliseconds since January 1, 1970, 00:00:00 GMT
represented by this value.
|
java.util.Date |
toUTCDate()
Returns this date/time value as a
Date using the UTC timezone
and Gregorian calendar. |
int getYear()
int getMonth()
int getDay()
int getHour()
int getMinute()
int getSecond()
java.util.Date toDate(java.util.Calendar calendar)
Date
using the specified
calendar. Updates the calendar fields from this date/time and calls
the calendar's getTime
method. Note that this calls Calendar.clear()
on the supplied calendar.calendar
- the calendar to use for date/time conversionjava.util.Date toUTCDate()
Date
using the UTC timezone
and Gregorian calendar. Since Modeler dates/times do not include timezone
information, this assumes the date/time is already based on UTC.long toMilliseconds()
date.toUTCDate().getTime()
(C) Copyright IBM Corp. 1994, 2015. All Rights Reserved.