|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.ObjectPeriod
The Period class represents a consecutive period of time.
| Constructor Summary | |
Period(java.util.Date begin,
java.util.Date end)
Creates a Period representing the time between the two given instants. |
|
| Method Summary | |
boolean |
cover(Period p)
Test if this period contains another period. |
java.util.Date |
getBegin()
Return the beginning of the period. |
java.util.Date |
getEnd()
Return the end of the period. |
Period |
intersect(Period p)
Calculate the intersection of this period with another period. |
boolean |
overlapWith(Period p)
Test if this Period overlaps with the given Period. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public Period(java.util.Date begin,
java.util.Date end)
throws TDOMException
begin - The beginning instant of the period. The beginning instant is part of the period.end - The ending instant of the period. The ending instant is not part of the period.
TDOMException - Throw TDOMException with exception code INVALID_TIME_EXTENT
if the beginning time is after or equal to the ending time.| Method Detail |
public java.util.Date getBegin()
public java.util.Date getEnd()
public boolean overlapWith(Period p)
p - Another Period to test.
public boolean cover(Period p)
p - Another period to be tested if it's in this period.
public Period intersect(Period p)
p - Another Period with which the intersection is asked.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||