|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.codehaus.mojo.dashboard.report.plugin.utils.TimePeriod
public class TimePeriod
Used to set the time period of the analysis.
Field Summary | |
---|---|
static TimePeriod |
DAY
1 day time period. |
static TimePeriod |
HOUR
1 hour time period. |
static TimePeriod |
MINUTE
1 minute time period. |
static TimePeriod |
MONTH
1 month time period. |
static TimePeriod |
WEEK
1 week time period. |
Method Summary | |
---|---|
int |
compareTo(java.lang.Object anotherPeriod)
Compare two periods. |
java.text.SimpleDateFormat |
getDateFormat()
Return the date format. |
java.lang.String |
getName()
Return the period name. |
static TimePeriod |
getPeriod(java.lang.String name)
Return the period associated to the specified name. |
java.util.Date |
normalize(java.util.Date date)
Normalize the specified date with current date format. |
java.lang.String |
normalizeToString(java.util.Date date)
Format the specified date to String. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final TimePeriod MINUTE
public static final TimePeriod HOUR
public static final TimePeriod DAY
public static final TimePeriod WEEK
public static final TimePeriod MONTH
Method Detail |
---|
public java.text.SimpleDateFormat getDateFormat()
public java.lang.String getName()
public java.util.Date normalize(java.util.Date date)
date
- Date to normalize
public java.lang.String normalizeToString(java.util.Date date)
date
- Date to format
public static TimePeriod getPeriod(java.lang.String name)
name
- Period name
public int compareTo(java.lang.Object anotherPeriod)
compareTo
in interface java.lang.Comparable
anotherPeriod
- The period to be compared.
Comparable.compareTo(java.lang.Object)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |