java.lang.Object
java.lang.Number
io.jenetics.jpx.Longitude
- All Implemented Interfaces:
Serializable
The longitude of the point. Decimal degrees, WGS84 datum, which must be within
the range of
[-180..180].- Since:
- 1.0
- Version:
- 2.0
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final doubleA constant holding the maximum value aLatitudevalue can have, 180 inclusively.static final LongitudeA constant holding the maximum value aLatitudevalue can have, 180 inclusively.static final doubleA constant holding the maximum value aLatitudevalue can have, -180 inclusively.static final LongitudeA constant holding the maximum value aLatitudevalue can have, -180 inclusively. -
Method Summary
Modifier and TypeMethodDescriptiondoubleReturn the longitude value in decimal degrees.booleanfloatinthashCode()intintValue()longstatic LongitudeofDegrees(double degrees) Create a new (decimal degrees)Longitudeobject.static LongitudeofRadians(double radians) Create a newLongitudevalue for the givenradians.doubleReturn the longitude in decimal degree.doubleReturn the longitude value in radians.toString()Methods inherited from class java.lang.Number
byteValue, shortValue
-
Field Details
-
MIN_DEGREES
A constant holding the maximum value aLatitudevalue can have, -180 inclusively.- Since:
- 2.0
- See Also:
-
MIN_VALUE
A constant holding the maximum value aLatitudevalue can have, -180 inclusively.- Since:
- 2.0
-
MAX_DEGREES
A constant holding the maximum value aLatitudevalue can have, 180 inclusively.- Since:
- 2.0
- See Also:
-
MAX_VALUE
A constant holding the maximum value aLatitudevalue can have, 180 inclusively.- Since:
- 2.0
-
-
Method Details
-
doubleValue
Return the longitude value in decimal degrees.- Specified by:
doubleValuein classNumber- Returns:
- the longitude value in decimal degrees
-
toRadians
Return the longitude value in radians.- Returns:
- the longitude value in radians
-
toDegrees
Return the longitude in decimal degree.- Returns:
- the longitude in decimal degree
-
intValue
-
longValue
-
floatValue
- Specified by:
floatValuein classNumber
-
hashCode
-
equals
-
toString
-
ofDegrees
Create a new (decimal degrees)Longitudeobject.- Parameters:
degrees- the longitude value in decimal degrees- Returns:
- a new (decimal degrees)
Longitudeobject - Throws:
IllegalArgumentException- if the given value is not within the range of[-180..180)
-
ofRadians
Create a newLongitudevalue for the givenradians.- Parameters:
radians- the longitude value in radians- Returns:
- a new
Longitudevalue for the givenradians - Throws:
IllegalArgumentException- if the given radians is not within the range of[-2*Pi..2*Pi]
-