public enum AngularUnit extends Enum<AngularUnit>
| Enum Constant and Description |
|---|
DEGREE
An AngularUnit representing degrees.
|
GRADIAN
An AngularUnit representing a gradian.
|
MINUTE
An AngularUnit representing arc-minutes.
|
RADIAN
An AngularUnit representing radians.
|
SECOND
An AngularUnit representing arc-seconds.
|
| Modifier and Type | Method and Description |
|---|---|
static double |
convert(double angle,
AngularUnit fromUnit,
AngularUnit toUnit)
Convert the specified angle to its equivalent value in another angular unit.
|
double |
getDegreesPerUnit()
Get the number of degrees equivalent to one of this unit of measure.
|
static AngularUnit |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static AngularUnit[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final AngularUnit DEGREE
public static final AngularUnit MINUTE
public static final AngularUnit SECOND
public static final AngularUnit RADIAN
public static final AngularUnit GRADIAN
public static AngularUnit[] values()
for (AngularUnit c : AngularUnit.values()) System.out.println(c);
public static AngularUnit 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 getDegreesPerUnit()
public static double convert(double angle,
AngularUnit fromUnit,
AngularUnit toUnit)
angle - An angle with unit fromUnitfromUnit - The angular unit of the specified angle.toUnit - The angular unit for the converted value.