Class BigDateTimeValueType
- java.lang.Object
-
- com.sun.msv.datatype.xsd.datetime.BigDateTimeValueType
-
- All Implemented Interfaces:
IDateTimeValueType
,Serializable
public class BigDateTimeValueType extends Object implements IDateTimeValueType
DateTimeValueType object that can hold all lexically valid dateTime value. This class provides:- Unlimited digits for year (e.g., "year 9999999999999999999999")
- Unlimited digits for fraction of second (e.g. 0.00000000000001 sec)
- Author:
- Kohsuke KAWAGUCHI
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description BigDateTimeValueType()
BigDateTimeValueType(BigDateTimeValueType base, TimeZone newTimeZone)
creates an instance with the specified BigDateTimeValueType, with modified time zone.BigDateTimeValueType(BigInteger year, int month, int day, int hour, int minute, BigDecimal second, TimeZone timeZone)
BigDateTimeValueType(BigInteger year, Integer month, Integer day, Integer hour, Integer minute, BigDecimal second, TimeZone timeZone)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description IDateTimeValueType
add(ITimeDurationValueType _rhs)
returns the result of addition of this object and TimeDuration.protected static int
compare(BigDateTimeValueType lhs, BigDateTimeValueType rhs)
compares two BigDateTimeValueType and returns one of the constant defined inComparator
.int
compare(IDateTimeValueType o)
compare two DateTimeValueType as defined in com.sun.msv.datatype/Comparatorprotected TimeZone
createJavaTimeZone()
Deprecated.usegetTimeZone()
.boolean
equals(BigDateTimeValueType lhs, BigDateTimeValueType rhs)
boolean
equals(IDateTimeValueType rhs)
boolean
equals(Object o)
BigDateTimeValueType
getBigValue()
Integer
getDay()
Integer
getHour()
Integer
getMinute()
Integer
getMonth()
BigDecimal
getSecond()
TimeZone
getTimeZone()
BigInteger
getYear()
int
hashCode()
IDateTimeValueType
normalize()
gets the normalized IDateTimeValueType.Calendar
toCalendar()
Approximates the value represented by this object into a Calendar object.String
toString()
gets a human-readable representation of this object.
-
-
-
Constructor Detail
-
BigDateTimeValueType
public BigDateTimeValueType(BigDateTimeValueType base, TimeZone newTimeZone)
creates an instance with the specified BigDateTimeValueType, with modified time zone. created object shares its date/time value component with the original one, so special care is necessary not to mutate those values.
-
BigDateTimeValueType
public BigDateTimeValueType(BigInteger year, int month, int day, int hour, int minute, BigDecimal second, TimeZone timeZone)
-
BigDateTimeValueType
public BigDateTimeValueType(BigInteger year, Integer month, Integer day, Integer hour, Integer minute, BigDecimal second, TimeZone timeZone)
-
BigDateTimeValueType
public BigDateTimeValueType()
-
-
Method Detail
-
getYear
public BigInteger getYear()
-
getMonth
public Integer getMonth()
-
getDay
public Integer getDay()
-
getHour
public Integer getHour()
-
getMinute
public Integer getMinute()
-
getSecond
public BigDecimal getSecond()
-
getTimeZone
public TimeZone getTimeZone()
-
getBigValue
public BigDateTimeValueType getBigValue()
- Specified by:
getBigValue
in interfaceIDateTimeValueType
-
equals
public boolean equals(IDateTimeValueType rhs)
-
equals
public boolean equals(BigDateTimeValueType lhs, BigDateTimeValueType rhs)
-
toString
public String toString()
gets a human-readable representation of this object. return value is not intended to be compliant with the canonical representation of "dateTime" type.
-
compare
public int compare(IDateTimeValueType o)
Description copied from interface:IDateTimeValueType
compare two DateTimeValueType as defined in com.sun.msv.datatype/Comparator- Specified by:
compare
in interfaceIDateTimeValueType
-
compare
protected static int compare(BigDateTimeValueType lhs, BigDateTimeValueType rhs)
compares two BigDateTimeValueType and returns one of the constant defined inComparator
. Order-relation between two dateTime is defined in http://www.w3.org/TR/xmlschema-2/#dateTime
-
normalize
public IDateTimeValueType normalize()
Description copied from interface:IDateTimeValueType
gets the normalized IDateTimeValueType. normalized value always has GMT timezone or no timezone- Specified by:
normalize
in interfaceIDateTimeValueType
-
add
public IDateTimeValueType add(ITimeDurationValueType _rhs)
Description copied from interface:IDateTimeValueType
returns the result of addition of this object and TimeDuration. this object will not be mutated.- Specified by:
add
in interfaceIDateTimeValueType
-
toCalendar
public Calendar toCalendar()
Description copied from interface:IDateTimeValueType
Approximates the value represented by this object into a Calendar object. This conversion may lose accuracy.- Specified by:
toCalendar
in interfaceIDateTimeValueType
-
createJavaTimeZone
protected TimeZone createJavaTimeZone()
Deprecated.usegetTimeZone()
.Creates the equivalent Java TimeZone object.- Returns:
- a non-null valid object.
-
-