|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.ucl.xpath.types.AnyType
org.ucl.xpath.types.AnySimpleType
org.ucl.xpath.types.AnyAtomicType
org.ucl.xpath.types.CtrType
org.ucl.xpath.types.XSDuration
org.ucl.xpath.types.XDTYearMonthDuration
A representation of the YearMonthDuration datatype
| Constructor Summary | |
XDTYearMonthDuration()
Initialises to a duration of no time (0years and 0months) |
|
XDTYearMonthDuration(int months)
Initialises to the given number of months |
|
XDTYearMonthDuration(int year,
int month,
boolean negative)
Initialises using the supplied parameters. |
|
| Method Summary | |
ResultSequence |
constructor(ResultSequence arg)
Creates a new ResultSequence consisting of the extractable time duration from the supplied ResultSequence |
ResultSequence |
div(ResultSequence arg)
Mathematical division between this duration stored and the supplied duration of time (of type XDTYearMonthDuration) |
boolean |
eq(AnyType arg)
Equality comparison between this and the supplied duration of time. |
boolean |
gt(AnyType arg)
Comparison between this and the supplied duration of time. |
boolean |
lt(AnyType arg)
Comparison between this and the supplied duration of time. |
ResultSequence |
minus(ResultSequence arg)
Mathematical subtraction between this duration stored and the supplied duration of time (of type XDTYearMonthDuration) |
int |
month()
Retrieves the number of months within the duration of time stored |
boolean |
negative()
Retrieves whether this duration represents a backward passage through time |
static XDTYearMonthDuration |
parseYMDuration(java.lang.String str)
Creates a new XDTYearMonthDuration by parsing the supplied String represented duration of time |
ResultSequence |
plus(ResultSequence arg)
Mathematical addition between this duration stored and the supplied duration of time (of type XDTYearMonthDuration) |
java.lang.String |
string_type()
Retrieves the datatype's full pathname |
java.lang.String |
string_value()
Retrieves a String representation of the duration of time stored |
ResultSequence |
times(ResultSequence arg)
Mathematical multiplication between this duration stored and the supplied duration of time (of type XDTYearMonthDuration) |
java.lang.String |
type_name()
Retrives the datatype's name |
int |
value()
Retrieves the duration of time stored as the number of months within it |
int |
year()
Retrieves the number of years within the duration of time stored |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public XDTYearMonthDuration(int year,
int month,
boolean negative)
year - Number of years in this duration of timemonth - Number of months in this duration of timenegative - True if this duration of time represents a backwards passage
through time. False otherwisepublic XDTYearMonthDuration(int months)
months - Number of months in the duration of timepublic XDTYearMonthDuration()
| Method Detail |
public static XDTYearMonthDuration parseYMDuration(java.lang.String str)
str - String represented duration of time
public java.lang.String type_name()
type_name in class CtrType
public ResultSequence constructor(ResultSequence arg)
throws DynamicError
constructor in class CtrTypearg - The ResultSequence from which to extract
DynamicErrorpublic boolean negative()
public int year()
public int month()
public java.lang.String string_value()
string_value in class AnyTypepublic java.lang.String string_type()
string_type in class AnyTypepublic int value()
public boolean eq(AnyType arg)
throws DynamicError
eq in interface CmpEqarg - The duration of time to compare with
DynamicError
public boolean lt(AnyType arg)
throws DynamicError
lt in interface CmpLtarg - The duration of time to compare with
DynamicError
public boolean gt(AnyType arg)
throws DynamicError
gt in interface CmpGtarg - The duration of time to compare with
DynamicError
public ResultSequence plus(ResultSequence arg)
throws DynamicError
plus in interface MathPlusarg - The duration of time to add
DynamicError
public ResultSequence minus(ResultSequence arg)
throws DynamicError
minus in interface MathMinusarg - The duration of time to subtract
DynamicError
public ResultSequence times(ResultSequence arg)
throws DynamicError
times in interface MathTimesarg - The duration of time to multiply by
DynamicError
public ResultSequence div(ResultSequence arg)
throws DynamicError
div in interface MathDivarg - The duration of time to divide by
DynamicError
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||