public final class Altitude extends Coordinates<VerticalCRS<?>> implements Measurable<Length>
vertical
altitude (MSL).
Note: The current implementation approximates the MSL altitude to the WGS-86 Ellipsoid Height. Future implementations will use lookup tables in order to correct for regional discrepencies.
Modifier and Type | Field and Description |
---|---|
static VerticalCRS<Altitude> |
CRS
Holds the coordinate reference system for all instances of this class.
|
Modifier and Type | Method and Description |
---|---|
int |
compareTo(Measurable<Length> measure) |
Altitude |
copy()
Returns a copy of these coordinates
allocated
by the calling thread (possibly on the stack). |
double |
doubleValue(Unit<Length> unit)
Returns the value of this measurable stated in the specified unit as
a
double . |
VerticalCRS<?> |
getCoordinateReferenceSystem()
Returns the reference system for this coordinates.
|
int |
getDimension()
OpenGIS® - The length of coordinate sequence (the number of entries).
|
double |
getOrdinate(int dimension)
OpenGIS® - Returns the ordinate at the specified dimension.
|
long |
longValue(Unit<Length> unit)
Returns the estimated integral value of this measurable stated in
the specified unit as a
long . |
static Altitude |
valueOf(double value,
Unit<Length> unit)
Returns the vertical position corresponding to the specified coordinates.
|
clone, getCoordinates, getPosition, setOrdinate, toString, toText
public static final VerticalCRS<Altitude> CRS
public static Altitude valueOf(double value, Unit<Length> unit)
value
- the mean sea level altitude stated in the specified unit.unit
- the length unit in which the altitude is stated.public VerticalCRS<?> getCoordinateReferenceSystem()
Coordinates
getCoordinateReferenceSystem
in class Coordinates<VerticalCRS<?>>
public int getDimension()
Coordinates
getDimension
in class Coordinates<VerticalCRS<?>>
public double getOrdinate(int dimension) throws java.lang.IndexOutOfBoundsException
Coordinates
getOrdinate
in class Coordinates<VerticalCRS<?>>
dimension
- The dimension in the range 0 to
dimension-1.java.lang.IndexOutOfBoundsException
- if the specified dimension is out
of bounds.public final double doubleValue(Unit<Length> unit)
Measurable
double
. If the measurable has too great a magnitude to
be represented as a double
, it will be converted to
Double.NEGATIVE_INFINITY
or
Double.POSITIVE_INFINITY
as appropriate.doubleValue
in interface Measurable<Length>
unit
- the unit in which this measurable value is stated.double
.public final long longValue(Unit<Length> unit)
Measurable
long
.
Note: This method differs from the Number.longValue()
in the sense that the closest integer value is returned
and an ArithmeticException is raised instead
of a bit truncation in case of overflow (safety critical).
longValue
in interface Measurable<Length>
unit
- the unit in which the measurable value is stated.long
.public int compareTo(Measurable<Length> measure)
compareTo
in interface java.lang.Comparable<Measurable<Length>>
public Altitude copy()
Coordinates
allocated
by the calling thread (possibly on the stack).copy
in interface javolution.lang.ValueType
copy
in class Coordinates<VerticalCRS<?>>