public static enum Geo.Unit extends Enum<Geo.Unit>
Enum Constant and Description |
---|
DEGREES |
KILOMETERS |
METERS |
MILES |
Modifier and Type | Method and Description |
---|---|
double |
toDegrees(double distance)
Convert distance to degrees (used internally only).
|
static Geo.Unit |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static Geo.Unit[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final Geo.Unit MILES
public static final Geo.Unit KILOMETERS
public static final Geo.Unit METERS
public static final Geo.Unit DEGREES
public static Geo.Unit[] values()
for (Geo.Unit c : Geo.Unit.values()) System.out.println(c);
public static Geo.Unit 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 double toDegrees(double distance)
distance
- the distance to convert.Copyright © 2012–2018. All rights reserved.