A lightweight class used to store coordinates on the 2-dimensional Cartesian plane.
It is distinct from {link Point}, which is a subclass of {link Geometry}. Unlike objects of type {link Point} (which contain additional information such as an envelope, a precision model, and spatial reference system information), a <code>Coordinate</code> only contains ordinate values and accessor methods.
<code>Coordinate</code>s are two-dimensional points, with an additional Z-ordinate. If an Z-ordinate value is not specified or not defined, constructed coordinates have a Z-ordinate of <code>NaN</code> (which is also the value of <code>NULL_ORDINATE</code>). The standard comparison functions ignore the Z-ordinate. Apart from the basic accessor functions, JTS supports only specific operations involving the Z-ordinate.
Implementations may optionally support Z-ordinate and M-measure values as appropriate for a {link CoordinateSequence}. Use of {link #getZ()} and {link #getM()} accessors, or {link #getOrdinate(int)} are recommended.
- Version
1.16
- Companion
- class
Type members
Classlikes
Compares two {link Coordinate}s, allowing for either a 2-dimensional or 3-dimensional comparison, and handling NaN values correctly.
Compares two {link Coordinate}s, allowing for either a 2-dimensional or 3-dimensional comparison, and handling NaN values correctly.
- Companion
- class
Value members
Concrete methods
Concrete fields
Standard ordinate index value for, where M is 3.
Standard ordinate index value for, where M is 3.
This constant assumes XYZM coordinate sequence definition, please check this assumption using {link #getDimension()} and {link #getMeasures()} before use.
The value used to indicate a null or missing ordinate value. In particular, used for the value of ordinates for dimensions greater than the defined dimension of a coordinate.
The value used to indicate a null or missing ordinate value. In particular, used for the value of ordinates for dimensions greater than the defined dimension of a coordinate.