Class BigTimeDurationValueType
java.lang.Object
com.sun.msv.datatype.xsd.datetime.BigTimeDurationValueType
- All Implemented Interfaces:
ITimeDurationValueType,Serializable
ITimeDurationValueType implementation that can hold all lexically legal
timeDuration value.
- Author:
- Kohsuke KAWAGUCHI
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected BigIntegerprotected BigIntegerprotected BigIntegerprotected BigIntegerprotected BigDecimalprotected intprotected BigInteger -
Constructor Summary
ConstructorsConstructorDescriptionBigTimeDurationValueType(int signum, BigInteger year, BigInteger month, BigInteger day, BigInteger hour, BigInteger minute, BigDecimal second) All the fields should be positive and use the signum field to determine the sign.BigTimeDurationValueType(String lexicalRepresentation) Reads in the lexical duration format. -
Method Summary
Modifier and TypeMethodDescriptionintcompare two ITimeDurationValueType as defined in com.sun.msv.datatype/Comparatorbooleanbooleanstatic BigTimeDurationValueTypefromMinutes(int minutes) static BigTimeDurationValueTypefromMinutes(BigInteger minutes) getDay()getHour()getMonth()getYear()inthashCode()hash code has to be consistent with equals method.toString()
-
Field Details
-
signum
protected int signum -
year
-
month
-
day
-
hour
-
minute
-
second
-
-
Constructor Details
-
BigTimeDurationValueType
public BigTimeDurationValueType(int signum, BigInteger year, BigInteger month, BigInteger day, BigInteger hour, BigInteger minute, BigDecimal second) All the fields should be positive and use the signum field to determine the sign. -
BigTimeDurationValueType
Reads in the lexical duration format.- Parameters:
lexicalRepresentation- whitespace stripped lexical form.- Throws:
IllegalArgumentException
-
-
Method Details
-
equals
-
equals
-
toString
-
hashCode
public int hashCode()hash code has to be consistent with equals method. -
compare
Description copied from interface:ITimeDurationValueTypecompare two ITimeDurationValueType as defined in com.sun.msv.datatype/Comparator- Specified by:
comparein interfaceITimeDurationValueType
-
getBigValue
- Specified by:
getBigValuein interfaceITimeDurationValueType
-
fromMinutes
-
fromMinutes
-
getDay
- Returns:
- non-null positive value. use
signumfor the sign.
-
getHour
- Returns:
- non-null positive value. use
signumfor the sign.
-
getMinute
- Returns:
- non-null positive value. use
signumfor the sign.
-
getMonth
- Returns:
- non-null positive value. use
signumfor the sign.
-
getSecond
- Returns:
- non-null positive value. use
signumfor the sign.
-
getYear
- Returns:
- non-null positive value. use
signumfor the sign.
-