public enum Resolution extends Enum<Resolution>
Values are declared in order of increasing resolution, starting with YEAR,
and finishing with NSEC (nanoseconds). It is however recommended to compare
resolutions with TimeDomain.compareResolutionTo(Resolution)
, rather
than relying on the natural ordering of this enum.
Enum Constant and Description |
---|
DAY
The smallest unit is a day.
|
HOUR
The smallest unit is an hour.
|
MIN
The smallest unit is a minute.
|
MONTH
The smallest unit is a month.
|
MSEC
The smallest unit is a millisecond.
|
NSEC
The smallest unit is a nanosecond.
|
SEC
The smallest unit is a second.
|
USEC
The smallest unit is a microsecond.
|
YEAR
The smallest unit is a year.
|
Modifier and Type | Method and Description |
---|---|
static Resolution |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static Resolution[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final Resolution YEAR
public static final Resolution MONTH
public static final Resolution DAY
public static final Resolution HOUR
public static final Resolution MIN
public static final Resolution SEC
public static final Resolution MSEC
public static final Resolution USEC
public static final Resolution NSEC
public static Resolution[] values()
for (Resolution c : Resolution.values()) System.out.println(c);
public static Resolution 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 nullCopyright © 2017. All rights reserved.