Package org.apache.commons.numbers.angle
Class Angle.Deg
- java.lang.Object
-
- org.apache.commons.numbers.angle.Angle
-
- org.apache.commons.numbers.angle.Angle.Deg
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.apache.commons.numbers.angle.Angle
Angle.Deg, Angle.Rad, Angle.Turn
-
-
Field Summary
Fields Modifier and Type Field Description static java.util.function.DoubleUnaryOperator
WITHIN_0_AND_360
Normalizing operator (result will be within the[0, 360[
interval).static Angle.Deg
ZERO
Zero.-
Fields inherited from class org.apache.commons.numbers.angle.Angle
PI_OVER_TWO, TWO_PI
-
-
Constructor Summary
Constructors Modifier Constructor Description private
Deg(double angle)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static java.util.function.DoubleUnaryOperator
normalizer(double lo)
Creates an operator for normalizing/reducing an angle.static Angle.Deg
of(double angle)
Angle.Deg
toDeg()
Angle.Rad
toRad()
Angle.Turn
toTurn()
-
Methods inherited from class org.apache.commons.numbers.angle.Angle
equals, getAsDouble, hashCode
-
-
-
-
Field Detail
-
ZERO
public static final Angle.Deg ZERO
Zero.
-
WITHIN_0_AND_360
public static final java.util.function.DoubleUnaryOperator WITHIN_0_AND_360
Normalizing operator (result will be within the[0, 360[
interval).
-
-
Method Detail
-
of
public static Angle.Deg of(double angle)
- Parameters:
angle
- (in degrees).- Returns:
- a new intance.
-
toTurn
public Angle.Turn toTurn()
-
normalizer
public static java.util.function.DoubleUnaryOperator normalizer(double lo)
Creates an operator for normalizing/reducing an angle. The output will be within the[c, c + 360[
interval.- Parameters:
lo
- Lower bound of the normalized interval.- Returns:
- the normalization operator.
-
-