com.esri.core.geometry
Class Point

java.lang.Object
  extended by com.esri.core.geometry.Geometry
      extended by com.esri.core.geometry.Point
All Implemented Interfaces:
Serializable

public final class Point
extends Geometry
implements Serializable

A Point feature geometry class

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class com.esri.core.geometry.Geometry
Geometry.Type
 
Field Summary
 
Fields inherited from class com.esri.core.geometry.Geometry
m_description
 
Constructor Summary
Point()
          Creates an empty 2 dimensional Point
Point(double x, double y)
          Creates a 2 dimensional Point with specified x and y coordinates
Point(double x, double y, double z)
          Creates a 3 dimensional Point with specified x, y and z coordinates
 
Method Summary
 void copyTo(Geometry dst)
          Copies this geometry to another Geometry of the same type.
 Geometry createInstance()
          Creates instance of empty Geometry with the same VertexDescription.
 boolean equals(Object _other)
           
 int getDimension()
          Returns the Geometry Dimension.
 int getID()
          Returns the ID of the point.
 double getM()
          Returns the attribute M of the point.
 Geometry.Type getType()
          Returns the Geometry type.
 double getX()
          Returns the X coordinate of the point.
 double getY()
          Returns the Y coordinate of the point.
 double getZ()
          Returns the Z coordinate of the point.
 int hashCode()
           
 boolean isEmpty()
          Returns True if the Geometry is empty.
 void setEmpty()
          Sets the Geometry as empty.
 void setID(int id)
          Sets the ID of the point.
 void setM(double m)
          Sets the M coordinate of the point.
 void setX(double x)
          Sets the X coordinate of the point.
 void setXY(double x, double y)
           
 void setY(double y)
          Sets the Y coordinate of the point.
 void setZ(double z)
          Sets the Z coordinate of the point.
 
Methods inherited from class com.esri.core.geometry.Geometry
_getImpl, addID, addM, addZ, calculateArea2D, calculateLength2D, hasID, hasM, hasZ, isSegment, queryEnvelope
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Point

public Point()
Creates an empty 2 dimensional Point


Point

public Point(double x,
             double y)
Creates a 2 dimensional Point with specified x and y coordinates


Point

public Point(double x,
             double y,
             double z)
Creates a 3 dimensional Point with specified x, y and z coordinates

Method Detail

getX

public double getX()
Returns the X coordinate of the point. Throws if Point is empty.


setX

public void setX(double x)
Sets the X coordinate of the point.


getY

public double getY()
Returns the Y coordinate of the point. Throws if Point is empty.


setY

public void setY(double y)
Sets the Y coordinate of the point.


getZ

public double getZ()
Returns the Z coordinate of the point. Throws if Point is empty.


setZ

public void setZ(double z)
Sets the Z coordinate of the point.


getM

public double getM()
Returns the attribute M of the point. Throws if Point is empty.


setM

public void setM(double m)
Sets the M coordinate of the point.


getID

public int getID()
Returns the ID of the point. Throws if Point is empty.


setID

public void setID(int id)
Sets the ID of the point.


getType

public Geometry.Type getType()
Description copied from class: Geometry
Returns the Geometry type.

Specified by:
getType in class Geometry

getDimension

public int getDimension()
Description copied from class: Geometry
Returns the Geometry Dimension. (0 for Point and MultiPoint, 1 for curves, 2 for objects that have area, 3 for objects with volume)

Specified by:
getDimension in class Geometry

setEmpty

public void setEmpty()
Description copied from class: Geometry
Sets the Geometry as empty.

Specified by:
setEmpty in class Geometry

copyTo

public void copyTo(Geometry dst)
Description copied from class: Geometry
Copies this geometry to another Geometry of the same type. The result Geometry is exact copy.

Specified by:
copyTo in class Geometry

createInstance

public Geometry createInstance()
Description copied from class: Geometry
Creates instance of empty Geometry with the same VertexDescription.

Specified by:
createInstance in class Geometry

isEmpty

public boolean isEmpty()
Description copied from class: Geometry
Returns True if the Geometry is empty.

Specified by:
isEmpty in class Geometry

setXY

public void setXY(double x,
                  double y)

equals

public boolean equals(Object _other)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object


Copyright © 2010. All Rights Reserved.