com.esri.arcgis.geometry
Interface IJSONConverterGeometry

All Superinterfaces:
Serializable
All Known Implementing Classes:
JSONConverterGeometry

public interface IJSONConverterGeometry
extends Serializable

Provides direct access to the geometry serialization for AMF and JSON formats.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.


Method Summary
 void queryJSONEnvelope(IEnvelope pEnvelope, boolean skip_spref, IJSONObject pJSON)
          Queries spatial reference and populates existing IJSONObject
 void queryJSONGeometry(IGeometry pGeom, boolean skip_spref, IJSONObject pJSON)
          Queries geometry and populates existing IJSONObject
 void queryJSONGeoTransformation(IGeoTransformation pSR, IJSONObject pJSON)
          Queries a geographic (datum) transformation object and populates existing IJSONObject
 void queryJSONSpatialReference(ISpatialReference pSR, IJSONObject pJSON)
          Queries spatial reference and populates existing IJSONObject
 IEnvelope readEnvelope(IJSONReader pReader)
          Reads point object.
 IGeometry readGeometry(IJSONReader pReader, int geomType, boolean bDefaultHasZs, boolean bDefaultHasMs)
          Reads geometry object.
 IGeoTransformation readGeoTransformation(IJSONReader pReader)
          Reads a geographic (datum) transformation object.
 IMultipoint readMultipoint(IJSONReader pReader, boolean bDefaultHasZs, boolean bDefaultHasMs)
          Reads point object.
 IPoint readPoint(IJSONReader pReader)
          Reads point object.
 IPolygon readPolygon(IJSONReader pReader, boolean bDefaultHasZs, boolean bDefaultHasMs)
          Reads point object.
 IPolyline readPolyline(IJSONReader pReader, boolean bDefaultHasZs, boolean bDefaultHasMs)
          Reads point object.
 ISpatialReference readSpatialReference(IJSONReader pReader)
          Reads spatial reference object.
 IEnvelope toEnvelope(IJSONObject pJSONObject)
          Reads envelope from a JSON object.
 IGeometry toGeometry(IJSONObject pJSONObject, int geomType, boolean bDefaultHasZs, boolean bDefaultHasMs)
          Reads geometry object from JSON object.
 IGeoTransformation toGeoTransformation(IJSONObject pJSONObject)
          Reads a geographic (datum) transformation object from a JSON object.
 IMultipoint toMultipoint(IJSONObject pJSONObject, boolean bDefaultHasZs, boolean bDefaultHasMs)
          Reads multipoint from a JSON object.
 IPoint toPoint(IJSONObject pJSONObject)
          Reads IPoint from a JSON object.
 IPolygon toPolygon(IJSONObject pJSONObject, boolean bDefaultHasZs, boolean bDefaultHasMs)
          Reads polygon from a JSON object.
 IPolyline toPolyline(IJSONObject pJSONObject, boolean bDefaultHasZs, boolean bDefaultHasMs)
          Reads polyline from a JSON object.
 ISpatialReference toSpatialReference(IJSONObject pJSONObject)
          Reads spatial reference from a JSON object.
 void writeGeometry(IJSONWriter pWriter, String propname, IGeometry pGeom, boolean skip_spref)
          Writes geometry object.
 void writeGeoTransformation(IJSONWriter pWriter, String propname, IGeoTransformation pSR)
          Writes a geographic (datum) transformation object.
 void writeSpatialReference(IJSONWriter pWriter, String propname, ISpatialReference pSR)
          Writes spatial reference object.
 

Method Detail

writeSpatialReference

void writeSpatialReference(IJSONWriter pWriter,
                           String propname,
                           ISpatialReference pSR)
                           throws IOException,
                                  AutomationException
Writes spatial reference object. Pass NULL as propname to write a standalone JSON object.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pWriter - A reference to a com.esri.arcgis.system.IJSONWriter (in)
propname - The propname (in)
pSR - A reference to a com.esri.arcgis.geometry.ISpatialReference (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

writeGeoTransformation

void writeGeoTransformation(IJSONWriter pWriter,
                            String propname,
                            IGeoTransformation pSR)
                            throws IOException,
                                   AutomationException
Writes a geographic (datum) transformation object. Pass NULL as propname to write a standalone JSON object.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pWriter - A reference to a com.esri.arcgis.system.IJSONWriter (in)
propname - The propname (in)
pSR - A reference to a com.esri.arcgis.geometry.IGeoTransformation (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

writeGeometry

void writeGeometry(IJSONWriter pWriter,
                   String propname,
                   IGeometry pGeom,
                   boolean skip_spref)
                   throws IOException,
                          AutomationException
Writes geometry object.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pWriter - A reference to a com.esri.arcgis.system.IJSONWriter (in)
propname - The propname (in)
pGeom - A reference to a com.esri.arcgis.geometry.IGeometry (in)
skip_spref - The skip_spref (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

queryJSONSpatialReference

void queryJSONSpatialReference(ISpatialReference pSR,
                               IJSONObject pJSON)
                               throws IOException,
                                      AutomationException
Queries spatial reference and populates existing IJSONObject

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pSR - A reference to a com.esri.arcgis.geometry.ISpatialReference (in)
pJSON - A reference to a com.esri.arcgis.system.IJSONObject (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

queryJSONGeoTransformation

void queryJSONGeoTransformation(IGeoTransformation pSR,
                                IJSONObject pJSON)
                                throws IOException,
                                       AutomationException
Queries a geographic (datum) transformation object and populates existing IJSONObject

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pSR - A reference to a com.esri.arcgis.geometry.IGeoTransformation (in)
pJSON - A reference to a com.esri.arcgis.system.IJSONObject (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

queryJSONEnvelope

void queryJSONEnvelope(IEnvelope pEnvelope,
                       boolean skip_spref,
                       IJSONObject pJSON)
                       throws IOException,
                              AutomationException
Queries spatial reference and populates existing IJSONObject

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pEnvelope - A reference to a com.esri.arcgis.geometry.IEnvelope (in)
skip_spref - The skip_spref (in)
pJSON - A reference to a com.esri.arcgis.system.IJSONObject (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

queryJSONGeometry

void queryJSONGeometry(IGeometry pGeom,
                       boolean skip_spref,
                       IJSONObject pJSON)
                       throws IOException,
                              AutomationException
Queries geometry and populates existing IJSONObject

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pGeom - A reference to a com.esri.arcgis.geometry.IGeometry (in)
skip_spref - The skip_spref (in)
pJSON - A reference to a com.esri.arcgis.system.IJSONObject (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

readSpatialReference

ISpatialReference readSpatialReference(IJSONReader pReader)
                                       throws IOException,
                                              AutomationException
Reads spatial reference object.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pReader - A reference to a com.esri.arcgis.system.IJSONReader (in)
Returns:
A reference to a com.esri.arcgis.geometry.ISpatialReference
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

readGeoTransformation

IGeoTransformation readGeoTransformation(IJSONReader pReader)
                                         throws IOException,
                                                AutomationException
Reads a geographic (datum) transformation object.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pReader - A reference to a com.esri.arcgis.system.IJSONReader (in)
Returns:
A reference to a com.esri.arcgis.geometry.IGeoTransformation
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

readGeometry

IGeometry readGeometry(IJSONReader pReader,
                       int geomType,
                       boolean bDefaultHasZs,
                       boolean bDefaultHasMs)
                       throws IOException,
                              AutomationException
Reads geometry object. If provided geometry type is esriUnknown, tries to deduce geometry type from the JSON structure.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pReader - A reference to a com.esri.arcgis.system.IJSONReader (in)
geomType - A com.esri.arcgis.geometry.esriGeometryType constant (in)
bDefaultHasZs - The bDefaultHasZs (in)
bDefaultHasMs - The bDefaultHasMs (in)
Returns:
A reference to a com.esri.arcgis.geometry.IGeometry
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

readPoint

IPoint readPoint(IJSONReader pReader)
                 throws IOException,
                        AutomationException
Reads point object.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pReader - A reference to a com.esri.arcgis.system.IJSONReader (in)
Returns:
A reference to a com.esri.arcgis.geometry.IPoint
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

readMultipoint

IMultipoint readMultipoint(IJSONReader pReader,
                           boolean bDefaultHasZs,
                           boolean bDefaultHasMs)
                           throws IOException,
                                  AutomationException
Reads point object.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pReader - A reference to a com.esri.arcgis.system.IJSONReader (in)
bDefaultHasZs - The bDefaultHasZs (in)
bDefaultHasMs - The bDefaultHasMs (in)
Returns:
A reference to a com.esri.arcgis.geometry.IMultipoint
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

readPolygon

IPolygon readPolygon(IJSONReader pReader,
                     boolean bDefaultHasZs,
                     boolean bDefaultHasMs)
                     throws IOException,
                            AutomationException
Reads point object.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pReader - A reference to a com.esri.arcgis.system.IJSONReader (in)
bDefaultHasZs - The bDefaultHasZs (in)
bDefaultHasMs - The bDefaultHasMs (in)
Returns:
A reference to a com.esri.arcgis.geometry.IPolygon
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

readPolyline

IPolyline readPolyline(IJSONReader pReader,
                       boolean bDefaultHasZs,
                       boolean bDefaultHasMs)
                       throws IOException,
                              AutomationException
Reads point object.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pReader - A reference to a com.esri.arcgis.system.IJSONReader (in)
bDefaultHasZs - The bDefaultHasZs (in)
bDefaultHasMs - The bDefaultHasMs (in)
Returns:
A reference to a com.esri.arcgis.geometry.IPolyline
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

readEnvelope

IEnvelope readEnvelope(IJSONReader pReader)
                       throws IOException,
                              AutomationException
Reads point object.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pReader - A reference to a com.esri.arcgis.system.IJSONReader (in)
Returns:
A reference to a com.esri.arcgis.geometry.IEnvelope
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

toGeometry

IGeometry toGeometry(IJSONObject pJSONObject,
                     int geomType,
                     boolean bDefaultHasZs,
                     boolean bDefaultHasMs)
                     throws IOException,
                            AutomationException
Reads geometry object from JSON object.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pJSONObject - A reference to a com.esri.arcgis.system.IJSONObject (in)
geomType - A com.esri.arcgis.geometry.esriGeometryType constant (in)
bDefaultHasZs - The bDefaultHasZs (in)
bDefaultHasMs - The bDefaultHasMs (in)
Returns:
A reference to a com.esri.arcgis.geometry.IGeometry
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

toEnvelope

IEnvelope toEnvelope(IJSONObject pJSONObject)
                     throws IOException,
                            AutomationException
Reads envelope from a JSON object.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pJSONObject - A reference to a com.esri.arcgis.system.IJSONObject (in)
Returns:
A reference to a com.esri.arcgis.geometry.IEnvelope
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

toSpatialReference

ISpatialReference toSpatialReference(IJSONObject pJSONObject)
                                     throws IOException,
                                            AutomationException
Reads spatial reference from a JSON object.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pJSONObject - A reference to a com.esri.arcgis.system.IJSONObject (in)
Returns:
A reference to a com.esri.arcgis.geometry.ISpatialReference
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

toGeoTransformation

IGeoTransformation toGeoTransformation(IJSONObject pJSONObject)
                                       throws IOException,
                                              AutomationException
Reads a geographic (datum) transformation object from a JSON object.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pJSONObject - A reference to a com.esri.arcgis.system.IJSONObject (in)
Returns:
A reference to a com.esri.arcgis.geometry.IGeoTransformation
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

toPoint

IPoint toPoint(IJSONObject pJSONObject)
               throws IOException,
                      AutomationException
Reads IPoint from a JSON object.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pJSONObject - A reference to a com.esri.arcgis.system.IJSONObject (in)
Returns:
A reference to a com.esri.arcgis.geometry.IPoint
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

toMultipoint

IMultipoint toMultipoint(IJSONObject pJSONObject,
                         boolean bDefaultHasZs,
                         boolean bDefaultHasMs)
                         throws IOException,
                                AutomationException
Reads multipoint from a JSON object.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pJSONObject - A reference to a com.esri.arcgis.system.IJSONObject (in)
bDefaultHasZs - The bDefaultHasZs (in)
bDefaultHasMs - The bDefaultHasMs (in)
Returns:
A reference to a com.esri.arcgis.geometry.IMultipoint
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

toPolygon

IPolygon toPolygon(IJSONObject pJSONObject,
                   boolean bDefaultHasZs,
                   boolean bDefaultHasMs)
                   throws IOException,
                          AutomationException
Reads polygon from a JSON object.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pJSONObject - A reference to a com.esri.arcgis.system.IJSONObject (in)
bDefaultHasZs - The bDefaultHasZs (in)
bDefaultHasMs - The bDefaultHasMs (in)
Returns:
A reference to a com.esri.arcgis.geometry.IPolygon
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

toPolyline

IPolyline toPolyline(IJSONObject pJSONObject,
                     boolean bDefaultHasZs,
                     boolean bDefaultHasMs)
                     throws IOException,
                            AutomationException
Reads polyline from a JSON object.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
pJSONObject - A reference to a com.esri.arcgis.system.IJSONObject (in)
bDefaultHasZs - The bDefaultHasZs (in)
bDefaultHasMs - The bDefaultHasMs (in)
Returns:
A reference to a com.esri.arcgis.geometry.IPolyline
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.