Spatial DataBlade
JAVA API v8.21

com.ibm.spatial.geom
Class CoordPoint.DoubleZM

java.lang.Object
  extended by com.ibm.spatial.geom.CoordPoint
      extended by com.ibm.spatial.geom.CoordPoint.Double
          extended by com.ibm.spatial.geom.CoordPoint.DoubleZM
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable
Enclosing class:
CoordPoint

public static class CoordPoint.DoubleZM
extends CoordPoint.Double

The CoordPoint.DoubleZM class defines a CoordPoint specified in double precision coordinates. Besides x and y, the point may have a z coordinate and a measure.

CoordPoint.DoubleZM objects which don't have a z coordinate or a measure will have the corresponding fields initialized to java.lang.Double.NaN. This is an implementation detail which may change in the future. The API users should use hasZ and hasM members in order to determine whether a CoordPoint.DoubleZM has a z coordinate or measure.

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class com.ibm.spatial.geom.CoordPoint
CoordPoint.Double, CoordPoint.DoubleZM, CoordPoint.Long, CoordPoint.LongZM
 
Field Summary
 double m
          The m coordinate of this CoordPoint.
 double z
          The z coordinate of this CoordPoint.
 
Fields inherited from class com.ibm.spatial.geom.CoordPoint.Double
x, y
 
Constructor Summary
CoordPoint.DoubleZM()
          Constructs a new CoordPoint.
CoordPoint.DoubleZM(CoordPoint point)
          Constructs and initializes a CoordPoint from the coordinates of the specified CoordPoint.
CoordPoint.DoubleZM(double x, double y)
          Constructs and initializes a CoordPoint from the specified coordinates.
CoordPoint.DoubleZM(double x, double y, double z, double m)
          Constructs and initializes a CoordPoint from the specified coordinates.
CoordPoint.DoubleZM(Point point)
          Constructs and initializes a CoordPoint from the coordinates of the specified OGC Point.
 
Method Summary
 double getM()
          Returns the measure associated to this CoordPoint.
 double getZ()
          Returns the Z coordinate of 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.
 boolean isEmpty()
          Tests whether this CoordPoint is empty.
 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.
 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.
 
Methods inherited from class com.ibm.spatial.geom.CoordPoint.Double
getX, getY, setCoord
 
Methods inherited from class com.ibm.spatial.geom.CoordPoint
clone, equals, equals, getCoordAt, hashCode, setCoord, toString
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

z

public double z
The z coordinate of this CoordPoint.


m

public double m
The m coordinate of this CoordPoint.

Constructor Detail

CoordPoint.DoubleZM

public CoordPoint.DoubleZM()
Constructs a new CoordPoint.


CoordPoint.DoubleZM

public CoordPoint.DoubleZM(double x,
                           double y)
Constructs and initializes a CoordPoint from the specified coordinates.

Parameters:
x - the x coordinate value of the newly constructed CoordPoint
y - the y coordinate value of the newly constructed CoordPoint

CoordPoint.DoubleZM

public CoordPoint.DoubleZM(double x,
                           double y,
                           double z,
                           double m)
Constructs and initializes a CoordPoint from the specified coordinates.

Parameters:
x - the x coordinate value of the newly constructed CoordPoint
y - the y coordinate value of the newly constructed CoordPoint
z - the z coordinate value of the newly constructed CoordPoint or java.lang.Double.NaN
m - the m value of the newly constructed CoordPoint or java.lang.Double.NaN

CoordPoint.DoubleZM

public CoordPoint.DoubleZM(CoordPoint point)
Constructs and initializes a CoordPoint from the coordinates of the specified CoordPoint.

Parameters:
point - the CoordPoint to be used for the newly constructed CoordPoint initialization

CoordPoint.DoubleZM

public CoordPoint.DoubleZM(Point point)
Constructs and initializes a CoordPoint from the coordinates of the specified OGC Point.

Parameters:
point - the OGC Point to be used for the newly constructed CoordPoint initialization
Method Detail

getZ

public double getZ()
Returns the Z coordinate of this CoordPoint.

Overrides:
getZ in class CoordPoint.Double
Returns:
the Z coordinate of this CoordPoint in double precision.

getM

public double getM()
Returns the measure associated to this CoordPoint.

Overrides:
getM in class CoordPoint.Double
Returns:
the measure of this CoordPoint in double precision.

setCoordAt

public void setCoordAt(int n,
                       double value)
                throws java.lang.IndexOutOfBoundsException
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.

Overrides:
setCoordAt in class CoordPoint.Double
Parameters:
n - the measure value
Throws:
java.lang.IndexOutOfBoundsException - id n < 0 or n > 3

setZ

public void setZ(double z)
Sets the coordinates of this CoordPoint to the specified values.

Overrides:
setZ in class CoordPoint
Parameters:
z - the z coordinate value

setM

public void setM(double m)
Sets the measure of this CoordPoint to the specified value.

Overrides:
setM in class CoordPoint
Parameters:
m - the measure value

setEmpty

public void setEmpty()
Sets this CoordPoint to be empty.

Overrides:
setEmpty in class CoordPoint.Double

isEmpty

public boolean isEmpty()
Tests whether this CoordPoint is empty.

Overrides:
isEmpty in class CoordPoint.Double
Returns:
true if this point is empty; otherwise, returns false

hasZ

public boolean hasZ()
Determines whether or not this CoordPoint has a Z coordinate.

Overrides:
hasZ in class CoordPoint
Returns:
true if this CoordPoint has a Z coordinate; false otherwise.

hasM

public boolean hasM()
Determines whether or not this CoordPoint has a measure.

Overrides:
hasM in class CoordPoint
Returns:
true if this CoordPoint has a measure; false otherwise.

Spatial DataBlade
JAVA API v8.21


Licensed Materials - Property of IBM
Copyright IBM Corp. 2002, 2012 All Rights Reserved.