|
Spatial DataBlade JAVA API v8.21 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.ibm.spatial.geom.CoordPoint
public abstract class CoordPoint
CoordPoint is a helper class that represents a coordinate point. Unlike a geometry Point that contains spatial reference system information, a coordinate point only contains coordinate values and methods to access them.
This class is only the abstract superclass for all objects that store a CoordPoint. The actual storage representation is left to the subclass.
Nested Class Summary | |
---|---|
static class |
CoordPoint.Double
The Double class defines a 2D CoordPoint specified in double precision coordinates. |
static class |
CoordPoint.DoubleZM
The CoordPoint.DoubleZM class defines a CoordPoint specified in double precision coordinates. |
static class |
CoordPoint.Long
The Long class defines a 2D CoordPoint specified in integer coordinates. |
static class |
CoordPoint.LongZM
The LongZM class defines a CoordPoint specified in integer coordinates. |
Method Summary | |
---|---|
java.lang.Object |
clone()
Return a copy of this object. |
boolean |
equals(java.lang.Object obj)
Determines whether or not the specified Object is equal to this CoordPoint. |
boolean |
equals(java.lang.Object obj,
double xyEpsilon,
double zEpsilon,
double mEpsilon)
Determines whether or not the specified Object is equal to this CoordPoint within precision limits specified by xyEpsilon, zEpsilon, mEpsilon). |
double |
getCoordAt(int n)
Gets the coordinate specified by index n, where n=0 corresponds to x, n=1 to y, n=2 to z, and n=3 to m. |
abstract double |
getM()
Returns the measure associated to this CoordPoint. |
abstract double |
getX()
Returns the X coordinate of this CoordPoint. |
abstract double |
getY()
Returns the Y coordinate of this CoordPoint. |
abstract double |
getZ()
Returns the Z coordinate of this CoordPoint. |
int |
hashCode()
Returns the hashcode for this CoordPoint. |
boolean |
hasM()
Determines whether or not this CoordPoint has a measure. |
boolean |
hasZ()
Determines whether or not this CoordPoint has a Z coordinate. |
abstract boolean |
isEmpty()
Tests whether this CoordPoint is empty. |
void |
setCoord(CoordPoint point)
Sets the coordinates of this CoordPoint to the values specified by the argument. |
abstract void |
setCoord(double x,
double y)
Sets the coordinates of this CoordPoint to the specified values. |
abstract void |
setCoordAt(int n,
double value)
Sets the coordinate specified by index n with the value specified by value, where n=0 corresponds to x, n=1 to y, n=2 to z, and n=3 to m. |
abstract void |
setEmpty()
Sets this CoordPoint to be empty. |
void |
setM(double m)
Sets the measure of this CoordPoint to the specified value. |
void |
setZ(double z)
Sets the coordinates of this CoordPoint to the specified values. |
java.lang.String |
toString()
Returns the String representation of this CoordPoint. |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, wait, wait, wait |
Method Detail |
---|
public double getCoordAt(int n)
n
- the measure value
java.lang.IndexOutOfBoundsException
- id n < 0 or n > 3public abstract double getX()
public abstract double getY()
public abstract double getZ()
public abstract double getM()
public abstract void setCoordAt(int n, double value)
n
- the measure valuepublic void setCoord(CoordPoint point)
point
- the point whose coordinate values are copied to this
objectpublic abstract void setCoord(double x, double y)
x
- the x coordinate valuey
- the y coordinate valuepublic void setZ(double z)
This implementation ignores the argument value.
z
- the z coordinate valuepublic void setM(double m)
This implementation ignores the argument value.
m
- the measure valuepublic abstract void setEmpty()
public abstract boolean isEmpty()
public boolean hasZ()
public boolean hasM()
public java.lang.String toString()
toString
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
obj
- an Object to be compared with this
CoordPoint.
public boolean equals(java.lang.Object obj, double xyEpsilon, double zEpsilon, double mEpsilon)
xyEpsilon
- the difference accepted between the x (or y)
coordinates of the objects tested for equality.zEpsilon
- the difference accepted between the z
coordinates of the objects tested for equality.mEpsilon
- the difference accepted between the m coordinates
(measures) of the objects tested for equality.
public java.lang.Object clone()
clone
in class java.lang.Object
|
Spatial DataBlade JAVA API v8.21 |
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |