|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.geotools.geometry.AbstractDirectPosition
public abstract class AbstractDirectPosition
Base class for direct position implementations. This base class
provides default implementations for toString()
, equals(java.lang.Object)
and hashCode()
methods.
This class do not holds any state. The decision to implement Serializable
or org.geotools.util.Cloneable
interfaces is left to implementors.
Constructor Summary | |
---|---|
protected |
AbstractDirectPosition()
Constructs a direct position. |
Method Summary | |
---|---|
boolean |
equals(java.lang.Object object)
Returns true if the specified object is also a direct position with equals coordinate and
CRS. |
double[] |
getCoordinate()
Returns a sequence of numbers that hold the coordinate of this position in its reference system. |
double[] |
getCoordinates()
Deprecated. Renamed as getCoordinate() for consistency with ISO 19107. |
org.opengis.geometry.DirectPosition |
getDirectPosition()
Returns always this , the direct position for this
position. |
org.opengis.geometry.DirectPosition |
getPosition()
Deprecated. Renamed as getDirectPosition() . |
int |
hashCode()
Returns a hash value for this coordinate. |
void |
setPosition(org.opengis.geometry.DirectPosition position)
Sets this direct position to the given position. |
java.lang.String |
toString()
Returns a string representation of this coordinate. |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface org.opengis.geometry.DirectPosition |
---|
getCoordinateReferenceSystem, getDimension, getOrdinate, setOrdinate |
Constructor Detail |
---|
protected AbstractDirectPosition()
Method Detail |
---|
@Deprecated public org.opengis.geometry.DirectPosition getPosition()
getDirectPosition()
.
getPosition
in interface org.opengis.geometry.coordinate.Position
public org.opengis.geometry.DirectPosition getDirectPosition()
this
, the direct position for this
position.
getDirectPosition
in interface org.opengis.geometry.coordinate.Position
public void setPosition(org.opengis.geometry.DirectPosition position)
null
, then all ordinate values are set to NaN.
position
- The new position.public double[] getCoordinate()
getCoordinate
in interface org.opengis.geometry.DirectPosition
@Deprecated public double[] getCoordinates()
getCoordinate()
for consistency with ISO 19107.
getCoordinates
in interface org.opengis.geometry.DirectPosition
public java.lang.String toString()
CoordinateFormat
.
toString
in class java.lang.Object
public int hashCode()
hashCode
in interface org.opengis.geometry.DirectPosition
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object object)
true
if the specified object is also a direct position with equals coordinate and
CRS.
equals
in interface org.opengis.geometry.DirectPosition
equals
in class java.lang.Object
object
- The object to compare with this position.
true
if the given object is equals to this position.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |