java.lang.Object | |
↳ | org.jfree.data.time.SimpleTimePeriod |
An arbitrary period of time, measured to millisecond precision using
java.util.Date
.
This class is intentionally immutable (that is, once constructed, you cannot alter the start and end attributes).
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Creates a new time allocation.
| |||||||||||
Creates a new time allocation.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Returns an integer that indicates the relative ordering of two
time periods.
| |||||||||||
Tests this time period instance for equality with an arbitrary object.
| |||||||||||
Returns the end date/time.
| |||||||||||
Returns the end date/time in milliseconds.
| |||||||||||
Returns the start date/time.
| |||||||||||
Returns the start date/time in milliseconds.
| |||||||||||
Returns a hash code for this object instance.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() | |||||||||||
![]() | |||||||||||
![]() |
Creates a new time allocation.
start | the start date/time in milliseconds. |
---|---|
end | the end date/time in milliseconds. |
Creates a new time allocation.
start | the start date/time (null not permitted). |
---|---|
end | the end date/time (null not permitted).
|
Returns an integer that indicates the relative ordering of two time periods.
obj | the object (null not permitted). |
---|
ClassCastException | if obj is not an instance of
TimePeriod .
|
---|
Tests this time period instance for equality with an arbitrary object.
The object is considered equal if it is an instance of TimePeriod
and it has the same start and end dates.
obj | the other object (null permitted). |
---|
Returns the end date/time in milliseconds.
Returns the start date/time in milliseconds.
Returns a hash code for this object instance. The approach described by Joshua Bloch in "Effective Java" has been used here - see:
http://developer.java.sun.com/
developer/Books/effectivejava/Chapter3.pdf