| java.lang.Object org.geotools.geometry.AbstractDirectPosition
All known Subclasses: org.geotools.geometry.DirectPosition1D, org.geotools.geometry.GeneralDirectPosition,
Method Summary | |
static void | checkCoordinateReferenceSystemDimension(CoordinateReferenceSystem crs, int expected) Convenience method for checking coordinate reference system validity. | public Object | clone() Returns a deep copy of this position. | static void | ensureDimensionMatch(String name, int dimension, int expectedDimension) Convenience method for checking object dimension validity. | public boolean | equals(Object object) Returns
true if the specified object is also a
with equals
and
. | public double[] | getCoordinates() Returns a sequence of numbers that hold the coordinate of this position in its
reference system. | public DirectPosition | getPosition() Returns always
this , the direct position for this
. | public int | hashCode() Returns a hash value for this coordinate. | static int | hashCode(DirectPosition position) Returns a hash value for the given coordinate. | public String | toString() Returns a string representation of this coordinate. | static String | toString(DirectPosition position) Formats the specified position. |
AbstractDirectPosition | protected AbstractDirectPosition()(Code) | | Constructs a direct position.
|
checkCoordinateReferenceSystemDimension | static void checkCoordinateReferenceSystemDimension(CoordinateReferenceSystem crs, int expected) throws MismatchedDimensionException(Code) | | Convenience method for checking coordinate reference system validity.
Parameters: crs - The coordinate reference system to check. Parameters: expected - the dimension expected. throws: MismatchedDimensionException - if the CRS dimension is not valid. |
clone | public Object clone()(Code) | | Returns a deep copy of this position.
|
ensureDimensionMatch | static void ensureDimensionMatch(String name, int dimension, int expectedDimension) throws MismatchedDimensionException(Code) | | Convenience method for checking object dimension validity.
This method is usually invoked for argument checking.
Parameters: name - The name of the argument to check. Parameters: dimension - The object dimension. Parameters: expectedDimension - The Expected dimension for the object. throws: MismatchedDimensionException - if the object doesn't have the expected dimension. |
equals | public boolean equals(Object object)(Code) | | Returns
true if the specified object is also a
with equals
and
.
|
getCoordinates | public double[] getCoordinates()(Code) | | Returns a sequence of numbers that hold the coordinate of this position in its
reference system.
The coordinates. |
getPosition | public DirectPosition getPosition()(Code) | | Returns always
this , the direct position for this
.
|
hashCode | public int hashCode()(Code) | | Returns a hash value for this coordinate.
|
hashCode | static int hashCode(DirectPosition position)(Code) | | Returns a hash value for the given coordinate.
|
toString | public String toString()(Code) | | Returns a string representation of this coordinate. The default implementation is okay
for occasional formatting (for example for debugging purpose). But if there is a lot
of positions to format, users will get more control by using their own instance of
org.geotools.measure.CoordinateFormat .
|
toString | static String toString(DirectPosition position)(Code) | | Formats the specified position.
|
|
|