com.esri.core.geometry
Class MapGeometry

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

public final class MapGeometry
extends Object
implements Serializable

The MapGeometry class bundles the geometry with its spatial reference together. To work with a geometry object in a map it is necessary to have a spatial reference defined for this geometry.

Since:
1.0
See Also:
Serialized Form

Constructor Summary
MapGeometry(Geometry g, SpatialReference _sr)
          Construct a MapGeometry instance using the specified geometry instance and its corresponding spatial reference.
 
Method Summary
 Geometry getGeometry()
          Gets the only geometry without the spatial reference from the MapGeometry.
 SpatialReference getSpatialReference()
          Gets the spatial reference for this MapGeometry.
 void setGeometry(Geometry geometry)
          Sets the geometry for this MapGeometry.
 void setSpatialReference(SpatialReference sr)
          Sets the spatial reference for this MapGeometry.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MapGeometry

public MapGeometry(Geometry g,
                   SpatialReference _sr)
Construct a MapGeometry instance using the specified geometry instance and its corresponding spatial reference.

Parameters:
g - The geometry to construct the new MapGeometry object.
_sr - The spatial reference of the geometry.
Since:
1.0
Method Detail

getGeometry

public Geometry getGeometry()
Gets the only geometry without the spatial reference from the MapGeometry.

Since:
1.0

setGeometry

public void setGeometry(Geometry geometry)
Sets the geometry for this MapGeometry.

Parameters:
geometry - The geometry.
Since:
1.0

setSpatialReference

public void setSpatialReference(SpatialReference sr)
Sets the spatial reference for this MapGeometry.

Parameters:
sr - The spatial reference.
Since:
1.0

getSpatialReference

public SpatialReference getSpatialReference()
Gets the spatial reference for this MapGeometry.

Since:
1.0


Copyright © 2012. All Rights Reserved.