public abstract class BaseDuration extends Object implements Comparable<BaseDuration>
Duration
Modifier and Type | Class and Description |
---|---|
static class |
BaseDuration.From |
Modifier and Type | Field and Description |
---|---|
protected int |
days |
protected int |
hours |
protected int |
millis |
protected int |
minutes |
protected int |
months |
protected int |
seconds |
protected int |
years |
Modifier | Constructor and Description |
---|---|
protected |
BaseDuration(int days,
int hours,
int minutes,
int seconds,
int millis) |
protected |
BaseDuration(int years,
int months,
int days,
int hours,
int minutes,
int seconds,
int millis) |
Modifier and Type | Method and Description |
---|---|
int |
compareTo(BaseDuration otherDuration) |
abstract Date |
getAgo() |
int |
getDays() |
abstract BaseDuration.From |
getFrom() |
int |
getHours() |
int |
getMillis() |
int |
getMinutes() |
int |
getMonths() |
int |
getSeconds() |
int |
getYears() |
Date |
plus(Date date) |
abstract long |
toMilliseconds() |
String |
toString() |
protected final int years
protected final int months
protected final int days
protected final int hours
protected final int minutes
protected final int seconds
protected final int millis
protected BaseDuration(int years, int months, int days, int hours, int minutes, int seconds, int millis)
protected BaseDuration(int days, int hours, int minutes, int seconds, int millis)
public int getYears()
public int getMonths()
public int getDays()
public int getHours()
public int getMinutes()
public int getSeconds()
public int getMillis()
public abstract long toMilliseconds()
public abstract Date getAgo()
public abstract BaseDuration.From getFrom()
public int compareTo(BaseDuration otherDuration)
compareTo
in interface Comparable<BaseDuration>