public final class MIDateTimeZone extends Object implements Comparable, Serializable
Month constants for month names to avoid confusion
and increase readability. Seconds are specified as a double, however, the value is only significant to three decimal
places (milliseconds).Month,
GregorianCalendar,
Serialized Form| Constructor and Description |
|---|
MIDateTimeZone(int year,
int month,
int day,
int hour,
int minute,
double seconds,
TimeZone timezone)
Constructs a new instance.
|
MIDateTimeZone(long milliSeconds,
TimeZone timezone)
Constructs a new instance.
|
MIDateTimeZone(MIDate date,
MITime time,
TimeZone timezone)
Constructs a new instance as a concatenation of a date, time, and timezone.
|
MIDateTimeZone(MIDateTime date,
TimeZone timezone)
Constructs a new instance as a concatenation of a MIDateTime and a TimeZone.
|
| Modifier and Type | Method and Description |
|---|---|
int |
compareTo(MIDateTimeZone dateTime) |
boolean |
equals(Object o) |
int |
getDay()
Returns the day of the month.
|
int |
getHour()
Returns the hour
|
int |
getMinute()
Returns the minute of the hour.
|
int |
getMonth()
Returns the month.
|
double |
getSeconds()
Returns the seconds.
|
long |
getTimeInMilliSeconds()
Returns the date and time as the number of milliseconds since the Epoch.
|
TimeZone |
getTimeZone()
Returns the timezone.
|
int |
getYear()
Returns the year.
|
int |
hashCode() |
String |
toString()
Returns the date time and timezone as MM/DD/YY hh:mm:ss z format.
|
public MIDateTimeZone(int year,
int month,
int day,
int hour,
int minute,
double seconds,
TimeZone timezone)
year - the year in the Gregorian calendarmonth - the month. Use the Month constants such as Month.FEBRUARY.day - the day of the month.hour - the hourminute - the minutes of the hourseconds - the seconds.timezone - the timezonepublic MIDateTimeZone(MIDateTime date, TimeZone timezone)
date - the date and timetimezone - the timezonepublic MIDateTimeZone(MIDate date, MITime time, TimeZone timezone)
date - the datetime - the timetimezone - the timezonepublic MIDateTimeZone(long milliSeconds,
TimeZone timezone)
Calendar.getTimeInMillis()
or System.currentTimeMillis().milliSeconds - time in milliseconds to use to initialize this instance.timezone - the timezone this time is expressed inpublic long getTimeInMilliSeconds()
Calendarpublic int getYear()
public int getMonth()
Month class (for example, Month.JANUARY).public int getDay()
public int getHour()
public int getMinute()
public double getSeconds()
public TimeZone getTimeZone()
public int compareTo(MIDateTimeZone dateTime)
compareTo in interface Comparable© 2007, 2022 Precisely. All rights reserved.