public enum TimeInterval extends Enum<TimeInterval>
Enum Constant and Description |
---|
FIVE_MONTHS
Five months.
|
FOUR_MONTHS
Four months.
|
FOUR_WEEKS
Four weeks.
|
ONE_MONTH
One month .
|
ONE_WEEK
One week.
|
ONE_YEAR
One year.
|
SIX_MONTHS
Six months.
|
THREE_MONTHS
Three months.
|
THREE_WEEKS
Three weeks.
|
TWO_MONTHS
Two months.
|
TWO_WEEKS
Two weeks.
|
Modifier and Type | Method and Description |
---|---|
static TimeInterval |
fromParameter(String parameter)
Returns the defined TimeInterval for the given parameter, defaults to ONE_MONTH for
unknown strings.
|
int |
getNumDays() |
String |
getParameter() |
static TimeInterval |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static TimeInterval[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final TimeInterval ONE_WEEK
public static final TimeInterval TWO_WEEKS
public static final TimeInterval THREE_WEEKS
public static final TimeInterval FOUR_WEEKS
public static final TimeInterval ONE_MONTH
public static final TimeInterval TWO_MONTHS
public static final TimeInterval THREE_MONTHS
public static final TimeInterval FOUR_MONTHS
public static final TimeInterval FIVE_MONTHS
public static final TimeInterval SIX_MONTHS
public static final TimeInterval ONE_YEAR
public static TimeInterval[] values()
for (TimeInterval c : TimeInterval.values()) System.out.println(c);
public static TimeInterval valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant
with the specified nameNullPointerException
- if the argument is nullpublic int getNumDays()
public String getParameter()
public static TimeInterval fromParameter(String parameter)
parameter
- the pramamter.Copyright © 2015 Collaborative Software Development Laboratory. All rights reserved.