|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--net.sf.bloof.metrics.TimeInterval
Represents a time interval. Acts as filter for a Metric
This class is used as an argument for a @link{MetricParameter}
Field Summary |
Fields inherited from interface net.sf.bloof.metrics.Filter |
DEFAULT_NAME_PREFIXES, DEVELOPER, FILE, TIMESPAN |
Constructor Summary | |
TimeInterval(java.util.Date aExactDate)
Creates a TimeInterval that represents only one @link{Date}, precice to a millisecond |
|
TimeInterval(java.util.Date aFrom,
java.util.Date aTo)
Creates a TimeInterval between the two specified @link{Date}s |
|
TimeInterval(java.lang.String aName,
java.util.Date aFrom,
java.util.Date aTo)
Creates a TimeInterval between the two specified @link{Date}s and sets its name |
|
TimeInterval(TimeInterval[] aIntervals)
Creates a TimeInterval on a list of Intervals |
Method Summary | |
java.lang.String |
getContent()
Returns the content of the filter as string |
int |
getFilterType()
Returns the type of the filter, must be one of Filter.FILE, Filter.DEVELOPER, Filter.TIMESPAN |
java.util.Date |
getFrom()
Returns the from. |
java.lang.String |
getName()
Returns the name. |
java.util.Date |
getTo()
Returns the to. |
boolean |
isSingleDate()
Checks if the Interval is empty and represents a single date |
void |
setName(java.lang.String aName)
Sets the name. |
java.lang.String |
toString()
(non-Javadoc) |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public TimeInterval(java.util.Date aExactDate)
aExactDate
- exact @link{Date} with Millisecond precisionpublic TimeInterval(java.util.Date aFrom, java.util.Date aTo)
aFrom
- interval starting @link{Date}aTo
- interval end @link{Date}public TimeInterval(java.lang.String aName, java.util.Date aFrom, java.util.Date aTo)
aName
- name of the time intervalaFrom
- interval starting @link{Date}aTo
- interval end @link{Date}public TimeInterval(TimeInterval[] aIntervals)
aIntervals
- interval list of IntervalsMethod Detail |
public java.lang.String getContent()
Filter
getContent
in interface Filter
Object.toString( )
public int getFilterType()
Filter
getFilterType
in interface Filter
Filter.getFilterType()
public java.util.Date getFrom()
public java.lang.String getName()
getName
in interface Filter
public java.util.Date getTo()
public boolean isSingleDate()
public void setName(java.lang.String aName)
setName
in interface Filter
aName
- The name to setpublic java.lang.String toString()
toString
in class java.lang.Object
Object.toString()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |