public class DatumDependentDuration extends BaseDuration
DatumDependentDuration represents durations whose length in milliseconds cannot be determined without knowing the datum point.
I don't know how many days in a year unless I know if it's a leap year or not.
I don't know how many days in a month unless I know the name of the month (and if it's a leap year if the month is February)
Constructor and description |
---|
DatumDependentDuration
(int years, int months, int days, int hours, int minutes, int seconds, int millis) |
Type Params | Return Type | Name and description |
---|---|---|
|
public Date |
getAgo() |
|
public BaseDuration.From |
getFrom() |
|
public int |
getMonths() |
|
public Date |
getNow() |
|
public int |
getYears() |
|
public DatumDependentDuration |
minus(DatumDependentDuration rhs) |
|
public DatumDependentDuration |
minus(Duration rhs) |
|
public DatumDependentDuration |
plus(DatumDependentDuration rhs) |
|
public DatumDependentDuration |
plus(TimeDatumDependentDuration rhs) |
|
public DatumDependentDuration |
plus(Duration rhs) |
|
public DatumDependentDuration |
plus(TimeDuration rhs) |
|
public long |
toMilliseconds()
|
Methods inherited from class | Name |
---|---|
class BaseDuration |
compareTo, getAgo, getDays, getFrom, getHours, getMillis, getMinutes, getMonths, getSeconds, getYears, plus, toMilliseconds, toString |
Copyright © 2003-2020 The Apache Software Foundation. All rights reserved.