- All Known Subinterfaces:
A type consisting of either a direct position or of a point from which a direct position shall be obtained. The use of this data type allows the identification of a position either directly as a coordinate (variant direct) or indirectly as a point (variant indirect).
- Departure from OGC/ISO abstract specification:
Departure due to constraint of the Java languageISO 19107 defines
Pointbut unions are not allowed in Java. GeoAPI defines
Positionas the base interface of both types so the two conditional accessor methods,
getDirectPosition(), can be replaced by an
instanceofcheck. However, the
getDirectPosition()has been retained with different semantics, conceptually returning a
DirectPositionat the same location. The conditionality has also been changed to mandatory since all three types conceptually have a well defined location.
getDirectPosition@UML(identifier="direct", obligation=CONDITIONAL, specification=ISO_19107) DirectPosition getDirectPosition()Returns the direct position. This method shall never returns
null, but may returns
thisif invoked on an object which is already a
- The direct position (may be