Class DCMIPeriod
java.lang.Object
org.opencastproject.metadata.dublincore.DCMIPeriod
A time interval, representing a DCMI period. They may be open.
For further information on DCMI periods please refer to http://dublincore.org/documents/dcmi-period/.
-
Constructor Summary
ConstructorsConstructorDescriptionDCMIPeriod(Date start, Date end) Create a new period.DCMIPeriod(Date start, Date end, String name) Create a new period with an optional name. -
Method Summary
Modifier and TypeMethodDescriptiongetEnd()Returns the end date of the period or null, if it has only a lower bound.getName()Returns the optional name of the period.getStart()Returns the start date of the period or null, if it has only an upper bound.booleanhasEnd()Checks if the interval has an end boundary.booleanhasName()Checks if the interval has a name.booleanhasStart()Checks if the interval has a start boundary.booleanisClosed()Checks if the interval is closed.toString()
-
Constructor Details
-
DCMIPeriod
Create a new period. To create an open interval you may set one of the boundaries null. -
DCMIPeriod
Create a new period with an optional name. To create an open interval you may set one of the bounbaries null.
-
-
Method Details
-
getStart
Returns the start date of the period or null, if it has only an upper bound. -
getEnd
Returns the end date of the period or null, if it has only a lower bound. -
getName
Returns the optional name of the period.- Returns:
- the name of the period or null
-
isClosed
public boolean isClosed()Checks if the interval is closed. -
hasStart
public boolean hasStart()Checks if the interval has a start boundary. -
hasEnd
public boolean hasEnd()Checks if the interval has an end boundary. -
hasName
public boolean hasName()Checks if the interval has a name. -
toString
-