public class IlrTime extends IlrTimeZone
time of the W3C XML Schema
recommendation (http://www.w3.org/TR/xmlschema-2/#time).EQUAL, GREATER, LOWER| Constructor and Description |
|---|
IlrTime()
Builds a time without any time zone.
|
IlrTime(java.util.Date date)
Builds a time without a time zone from a date.
|
IlrTime(java.util.Date date,
java.util.TimeZone timeZone)
Builds a time from a date and a time zone.
|
IlrTime(long l)
Builds an
IlrTime from a long. |
IlrTime(java.lang.String str)
Builds a time from a string.
|
| Modifier and Type | Method and Description |
|---|---|
int |
compareTo(IlrTime date)
Compares two times.
|
boolean |
equals(java.lang.Object obj) |
java.lang.String |
getFractionalSecond()
Get the remaining millisecond.
|
short |
getHour()
Gets the hour.
|
short |
getMillisecond()
Gets the millisecond.
|
short |
getMinute()
Gets the minute.
|
short |
getSecond()
Gets the second.
|
boolean |
isEqual(IlrTime dt)
Determines if two times are equal.
|
boolean |
isPositive()
Determines if the time is positive.
|
static IlrTime |
parse(java.lang.String str)
Creates a time from a string.
|
void |
set(java.util.Date date)
Sets a time from a date.
|
void |
set(java.util.Date date,
java.util.TimeZone timeZone)
Sets a time from a date and a time zone.
|
void |
setPositive(boolean positive)
Sets the time as positive.
|
void |
setTime(short hour,
short minute,
short second,
short millisecond)
Sets a time from hour/minute/second/millisecond.
|
java.util.Date |
toDate()
Converts the time to a date.
|
java.lang.String |
toString() |
static IlrTime |
valueOf(java.lang.String str)
Creates a time from a string.
|
formatToString, formatToString, getTimeZoneInMillis, getZoneHour, getZoneMinute, isEqual, isUTC, isZonePositive, setTimeZone, setTimeZoneInMillis, setUTC, toTimeZone, unsetUTCpublic IlrTime()
public IlrTime(long l)
IlrTime from a long.l - The long parameterpublic IlrTime(java.util.Date date)
public IlrTime(java.util.Date date,
java.util.TimeZone timeZone)
public IlrTime(java.lang.String str)
throws IlrDateFormatException
IlrDateFormatException - When the string format is invalid.public void set(java.util.Date date)
public void set(java.util.Date date,
java.util.TimeZone timeZone)
public void setTime(short hour,
short minute,
short second,
short millisecond)
public void setPositive(boolean positive)
public boolean isPositive()
public short getHour()
public short getMinute()
public short getSecond()
public short getMillisecond()
public java.lang.String getFractionalSecond()
public java.util.Date toDate()
throws IlrDateFormatException
IlrDateFormatExceptionpublic java.lang.String toString()
toString in class IlrTimeZonepublic boolean isEqual(IlrTime dt)
public boolean equals(java.lang.Object obj)
equals in class IlrTimeZonepublic int compareTo(IlrTime date)
public static IlrTime parse(java.lang.String str) throws IlrDateFormatException
IlrDateFormatException - When the string format is invalid.public static IlrTime valueOf(java.lang.String str)
IlrDateFormatException - When the string format is invalid.© Copyright IBM Corp. 1987, 2017