public class HourIntervalsVO extends Object implements Serializable
HourIntervalVO
,
HourIntervalsPropertyType
,
Serialized FormConstructor and Description |
---|
HourIntervalsVO() |
Modifier and Type | Method and Description |
---|---|
void |
add(HourIntervalVO interval)
Adds an hour interval to the list.
|
boolean |
equals(Object obj) |
HourIntervalVO |
get(int index)
Gets the n'th hour interval
|
Date |
getRandomHourMinute()
Gets a new Date (current date) where the hour and minute is randomly selected within a randomly selected hour interval.
|
Date |
getRandomHourMinute(Date date)
Set the hour and minute on already existing date, hour and minute is a randomly selected within a randomly selected hour interval.
|
HourIntervalVO |
getRandomInterval()
A random PropertyValidationVO from the list.
|
int |
hashCode() |
HourIntervalVO |
remove(int index)
Remove an hour interval from the list on an index.
|
int |
size()
The number of hour intervals.
|
String |
toString() |
public void add(HourIntervalVO interval)
interval
- a new interval.HourIntervalVO
public HourIntervalVO remove(int index)
index
- the index to be removed.public int size()
public HourIntervalVO get(int index)
index
- the interval index.HourIntervalVO
public HourIntervalVO getRandomInterval() throws NullPointerException
NullPointerException
- if no PropertyValidationVO has been added to the list.public Date getRandomHourMinute()
public Date getRandomHourMinute(Date date)
date
- the date where to set hour and minute.