public class TimeInterval extends Object
At the time of creation, the time interval is always specified as a string input. The input contains a numeric part suffixed with a 's', 'm', 'h' or 'd' to signify that the numeric value is in seconds, minutes, hours or days. Note that there should not be any whitespace between the numeric part and the suffix.
| Constructor and Description |
|---|
TimeInterval()
Creates a time interval with internal value of -1 (invalid/unset value).
|
TimeInterval(String timeValue)
Creates a time interval populated with information from the specified string
value.
|
| Modifier and Type | Method and Description |
|---|---|
long |
getValue()
Retrieves the internally stored time interval value.
|
void |
setValue(String timeValue)
Populates the time interval with information from the specified string value.
|
public TimeInterval()
public TimeInterval(String timeValue)
timeValue - the information for initializing a time inerval value.public void setValue(String timeValue)
timeValue - the information for initializing a time inerval value.public long getValue()
Copyright © 2016. All rights reserved.