public static enum DistanceUtil.DistanceUnit extends Enum<DistanceUtil.DistanceUnit>
Enum Constant and Description |
---|
FOOT
Imperial foot.
|
KILOMETER
Metric kilometer.
|
METER
Metric meter.
|
MILE
Imperial mile (standard).
|
Modifier and Type | Method and Description |
---|---|
static DistanceUtil.DistanceUnit |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static DistanceUtil.DistanceUnit[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final DistanceUtil.DistanceUnit METER
public static final DistanceUtil.DistanceUnit KILOMETER
public static final DistanceUtil.DistanceUnit MILE
public static final DistanceUtil.DistanceUnit FOOT
public static DistanceUtil.DistanceUnit[] values()
for (DistanceUtil.DistanceUnit c : DistanceUtil.DistanceUnit.values()) System.out.println(c);
public static DistanceUtil.DistanceUnit 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 null