@Immutable
public class CalendarDuration
extends java.lang.Object
change to JSR-310 javax.time.Duration when ready relation to javax.xml.datatype ?
Constructor and Description |
---|
CalendarDuration(int value,
CalendarPeriod.Field timeUnit) |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object o) |
static CalendarDuration |
fromUnitString(java.lang.String unitString) |
CalendarPeriod.Field |
getTimeUnit() |
double |
getValue()
Get the duration in natural units, ie units of getTimeUnit()
|
int |
hashCode() |
static void |
main(java.lang.String[] args) |
java.lang.String |
toString()
String representation
|
public CalendarDuration(int value, CalendarPeriod.Field timeUnit)
public CalendarPeriod.Field getTimeUnit()
public static CalendarDuration fromUnitString(java.lang.String unitString)
public double getValue()
public java.lang.String toString()
toString
in class java.lang.Object
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public static void main(java.lang.String[] args) throws java.lang.Exception
java.lang.Exception