com.esri.arcgis.geometry
Class ISpatialReferenceProxy

java.lang.Object
  extended bycom.esri.arcgis.interop.Dispatch
      extended bycom.esri.arcgis.geometry.ISpatialReferenceInfoProxy
          extended bycom.esri.arcgis.geometry.ISpatialReferenceProxy
All Implemented Interfaces:
java.io.Externalizable, ISpatialReference, ISpatialReferenceInfo, java.io.Serializable
Direct Known Subclasses:
IGeographicCoordinateSystemProxy, IProjectedCoordinateSystemProxy, ISpatialReference2Proxy, IUnknownCoordinateSystemProxy

public class ISpatialReferenceProxy
extends ISpatialReferenceInfoProxy
implements ISpatialReference, java.io.Serializable

Provides access to members that control a SpatialReference.

Product Availability

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

See Also:
Serialized Form

Field Summary
static java.lang.Class targetClass
           
 
Fields inherited from class com.esri.arcgis.interop.Dispatch
DISPATCH_METHOD, DISPATCH_PROPERTYGET, DISPATCH_PROPERTYPUT, DISPATCH_PROPERTYPUTREF
 
Constructor Summary
  ISpatialReferenceProxy()
          For internal use only
  ISpatialReferenceProxy(java.lang.Object obj)
           
protected ISpatialReferenceProxy(java.lang.Object obj, java.lang.String iid)
           
  ISpatialReferenceProxy(java.lang.String CLSID, java.lang.String host, AuthInfo authInfo)
           
protected ISpatialReferenceProxy(java.lang.String CLSID, java.lang.String iid, java.lang.String host, AuthInfo authInfo)
           
 
Method Summary
 void addListener(java.lang.String iidStr, java.lang.Object theListener, java.lang.Object theSource)
          Adds a Java object to be a listener for a specific kind of event generated by the COM object.
 void changed()
          Notify this object that some of its parts have changed (parameter values, z unit, etc.).
 void getDomain(double[] xMin, double[] xMax, double[] yMin, double[] yMax)
          The XY domain extent.
 void getFalseOriginAndUnits(double[] falseX, double[] falseY, double[] xyUnits)
          Get the false origin and units.
 void getMDomain(double[] outMMin, double[] outMMax)
          The measure domain extent.
 void getMFalseOriginAndUnits(double[] falseM, double[] mUnits)
          Get the measure false origin and units.
 ILinearUnit getZCoordinateUnit()
          The unit for the Z coordinate.
 void getZDomain(double[] outZMin, double[] outZMax)
          The Z domain extent.
 void getZFalseOriginAndUnits(double[] falseZ, double[] zUnits)
          Get the Z false origin and units.
 boolean hasMPrecision()
          Returns true when m-value precision information has been defined.
 boolean hasXYPrecision()
          Returns true when (x,y) precision information has been defined.
 boolean hasZPrecision()
          Returns true when z-value precision information has been defined.
 void isPrecisionEqual(ISpatialReference otherSR, boolean[] isPrecisionEqual)
          Returns TRUE when the precision information for the two spatial references is the same.
 void removeListener(java.lang.String iidStr, java.lang.Object theListener)
          Removes a Java object as a listener to events generated by a COM object.
 void setDomain(double xMin, double xMax, double yMin, double yMax)
          The XY domain extent.
 void setFalseOriginAndUnits(double falseX, double falseY, double xyUnits)
          Set the false origin and units.
 void setMDomain(double inMMin, double inMMax)
          The measure domain extent.
 void setMFalseOriginAndUnits(double falseM, double mUnits)
          Set the measure false origin and units.
 void setZCoordinateUnit(ILinearUnit zunit)
          The unit for the Z coordinate.
 void setZDomain(double inZMin, double inZMax)
          The Z domain extent.
 void setZFalseOriginAndUnits(double falseZ, double zUnits)
          Set the Z false origin and units.
 
Methods inherited from class com.esri.arcgis.geometry.ISpatialReferenceInfoProxy
getAbbreviation, getAlias, getFactoryCode, getName, getRemarks
 
Methods inherited from class com.esri.arcgis.interop.Dispatch
bindUsingMoniker, convertToNative, cookieForListener, createDispatch, createObjrefMonikerDisplayName, equals, getActiveObject, getActiveObject, getDefaultProperty, getDispatchIdOfName, getLastErrorCode, getMtsObjectContext, getObjRef, getPropertyByName, getPropertyByName, hashCode, invoke, invokeMethodByName, invokeMethodByName, invokeMethodByName, invokePropertyGetByName, invokePropertyPutByName, invokePropertyPutByRefByName, isNativeMode, isObjRef, queryInterface, readExternal, setNativeMode, setPropertyByName, toString, vtblInvoke, writeExternal
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface com.esri.arcgis.geometry.ISpatialReferenceInfo
getAbbreviation, getAlias, getFactoryCode, getName, getRemarks
 

Field Detail

targetClass

public static final java.lang.Class targetClass
Constructor Detail

ISpatialReferenceProxy

public ISpatialReferenceProxy(java.lang.String CLSID,
                              java.lang.String host,
                              AuthInfo authInfo)
                       throws java.net.UnknownHostException,
                              java.io.IOException

ISpatialReferenceProxy

public ISpatialReferenceProxy()
For internal use only


ISpatialReferenceProxy

public ISpatialReferenceProxy(java.lang.Object obj)
                       throws java.io.IOException

ISpatialReferenceProxy

protected ISpatialReferenceProxy(java.lang.Object obj,
                                 java.lang.String iid)
                          throws java.io.IOException

ISpatialReferenceProxy

protected ISpatialReferenceProxy(java.lang.String CLSID,
                                 java.lang.String iid,
                                 java.lang.String host,
                                 AuthInfo authInfo)
                          throws java.io.IOException
Method Detail

addListener

public void addListener(java.lang.String iidStr,
                        java.lang.Object theListener,
                        java.lang.Object theSource)
                 throws java.io.IOException
Description copied from class: Dispatch
Adds a Java object to be a listener for a specific kind of event generated by the COM object. when you wish to invoke method on the COM object using IDispatch (not using custom marshalling).

Overrides:
addListener in class ISpatialReferenceInfoProxy
Throws:
java.io.IOException

removeListener

public void removeListener(java.lang.String iidStr,
                           java.lang.Object theListener)
                    throws java.io.IOException
Description copied from class: Dispatch
Removes a Java object as a listener to events generated by a COM object. when you wish to invoke method on the COM object using IDispatch (not using custom marshalling).

Overrides:
removeListener in class ISpatialReferenceInfoProxy
Throws:
java.io.IOException

hasXYPrecision

public boolean hasXYPrecision()
                       throws java.io.IOException,
                              AutomationException
Description copied from interface: ISpatialReference
Returns true when (x,y) precision information has been defined.

Supported Platforms

Windows, Solaris, Linux

Specified by:
hasXYPrecision in interface ISpatialReference
Returns:
The hasXYPrecision
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

hasZPrecision

public boolean hasZPrecision()
                      throws java.io.IOException,
                             AutomationException
Description copied from interface: ISpatialReference
Returns true when z-value precision information has been defined.

Supported Platforms

Windows, Solaris, Linux

Specified by:
hasZPrecision in interface ISpatialReference
Returns:
The hasZPrecision
Throws:
AutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.

hasMPrecision

public boolean hasMPrecision()
                      throws java.io.IOException,
                             AutomationException
Description copied from interface: ISpatialReference
Returns true when m-value precision information has been defined.

Supported Platforms

Windows, Solaris, Linux

Specified by:
hasMPrecision in interface ISpatialReference
Returns:
The hasMPrecision
Throws:
AutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.

isPrecisionEqual

public void isPrecisionEqual(ISpatialReference otherSR,
                             boolean[] isPrecisionEqual)
                      throws java.io.IOException,
                             AutomationException
Description copied from interface: ISpatialReference
Returns TRUE when the precision information for the two spatial references is the same.

Supported Platforms

Windows, Solaris, Linux

Remarks

The IClone::IsEqual method implementation for spatial references only compares the coordinate system (projection information) portion of the spatial reference. If, in addition, you need to verify that the coordinate grid portions of the spatial references are equal, apply this method after IsEqual. The XY, Z, or M domain and resolution (precision) values, as well as the XY, Z and M cluster tolerances are compared.

Specified by:
isPrecisionEqual in interface ISpatialReference
Parameters:
otherSR - A reference to a com.esri.arcgis.geometry.ISpatialReference (in)
isPrecisionEqual - The isPrecisionEqual (out: use single element array)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setFalseOriginAndUnits

public void setFalseOriginAndUnits(double falseX,
                                   double falseY,
                                   double xyUnits)
                            throws java.io.IOException,
                                   AutomationException
Description copied from interface: ISpatialReference
Set the false origin and units.

Specified by:
setFalseOriginAndUnits in interface ISpatialReference
Parameters:
falseX - The falseX (in)
falseY - The falseY (in)
xyUnits - The xyUnits (in)
Throws:
AutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.

setZFalseOriginAndUnits

public void setZFalseOriginAndUnits(double falseZ,
                                    double zUnits)
                             throws java.io.IOException,
                                    AutomationException
Description copied from interface: ISpatialReference
Set the Z false origin and units.

Specified by:
setZFalseOriginAndUnits in interface ISpatialReference
Parameters:
falseZ - The falseZ (in)
zUnits - The zUnits (in)
Throws:
AutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.

setMFalseOriginAndUnits

public void setMFalseOriginAndUnits(double falseM,
                                    double mUnits)
                             throws java.io.IOException,
                                    AutomationException
Description copied from interface: ISpatialReference
Set the measure false origin and units.

Specified by:
setMFalseOriginAndUnits in interface ISpatialReference
Parameters:
falseM - The falseM (in)
mUnits - The mUnits (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getFalseOriginAndUnits

public void getFalseOriginAndUnits(double[] falseX,
                                   double[] falseY,
                                   double[] xyUnits)
                            throws java.io.IOException,
                                   AutomationException
Description copied from interface: ISpatialReference
Get the false origin and units.

Supported Platforms

Windows, Solaris, Linux

Description

An alternative method to the GetDomain method. The falseX and falseY values correspond to the minimum X and minimum Y values of the XY domain. The xyUnits is the same as the precision or scale value. The inverse of the xyUnits defines the resolution of the data stored in the geodatabase. The resolution is used to snap data when it is stored in the geodatabase.

The falseX, falseY, and xyUnits use the same unit of measure as the coordinate system.

Sample values if data is based on a geographic coordinate system are:

falseX = -180
falseY = -90
xyUnits = 1000000

Sample values if data is based on a projected coordinate system are:

 
falseX = 200000
falseY = 4000000
xyUnits = 100

In the first example, the data is using a geographic coordinate system so the falseX and falseY values are in degrees. The inverse of the xyUnits is 0.000001 degrees.

In the second example, the data is using a projected coordinate system. Let us assume that the unit of measure is meters. The smallest coordinates values that a feature can have is x = 200000 meters and Y = 4000000 meters. The inverse of the xyUnits is 0.01 (meters) which means data will be snapped to the closest centimeter when it is stored.

Remarks

Use this function to retrieve the following information about the spatial reference of the geometry:

falseX: XMin of the domain.

falseY: YMin of the domain.

XYUnits: Precision of the domain.

Specified by:
getFalseOriginAndUnits in interface ISpatialReference
Parameters:
falseX - The falseX (out: use single element array)
falseY - The falseY (out: use single element array)
xyUnits - The xyUnits (out: use single element array)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getZFalseOriginAndUnits

public void getZFalseOriginAndUnits(double[] falseZ,
                                    double[] zUnits)
                             throws java.io.IOException,
                                    AutomationException
Description copied from interface: ISpatialReference
Get the Z false origin and units.

Supported Platforms

Windows, Solaris, Linux

Description

An alternative method to the GetZDomain method. The falseZ value corresponds to the minimum Z value of the Z domain. The zUnits is the same as the precision or scale value. The inverse of the zUnits defines the resolution of the z data stored in the geodatabase. The resolution is used to snap data when it is stored in the geodatabase.

Specified by:
getZFalseOriginAndUnits in interface ISpatialReference
Parameters:
falseZ - The falseZ (out: use single element array)
zUnits - The zUnits (out: use single element array)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.
See Also:
ISpatialReferenceResolution

getMFalseOriginAndUnits

public void getMFalseOriginAndUnits(double[] falseM,
                                    double[] mUnits)
                             throws java.io.IOException,
                                    AutomationException
Description copied from interface: ISpatialReference
Get the measure false origin and units.

Supported Platforms

Windows, Solaris, Linux

Description

An alternative method to the GetMDomain method. The falseM value corresponds to the minimum measure value of the measure domain. The mUnits is the same as the precision or scale value. The inverse of the mUnits defines the resolution of the measure data stored in the geodatabase. The resolution is used to snap data when it is stored in the geodatabase.

Specified by:
getMFalseOriginAndUnits in interface ISpatialReference
Parameters:
falseM - The falseM (out: use single element array)
mUnits - The mUnits (out: use single element array)
Throws:
AutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.

getDomain

public void getDomain(double[] xMin,
                      double[] xMax,
                      double[] yMin,
                      double[] yMax)
               throws java.io.IOException,
                      AutomationException
Description copied from interface: ISpatialReference
The XY domain extent.

Supported Platforms

Windows, Solaris, Linux

Description

An alternative method to the GetFalseOriginAndUnits method. Returns the minimum and maximum allowed X and Y values for a spatial reference. Use GetFalseOriginAndUnits to obtain the allowed precision (1/resolution) value.

Remarks

The GetDomain and SetDomain methods are used to set and get the square domain extent of a coordinate system. The domain extent is different than the valid area of a coordinate system. The domain extent is an arbitrary square used to delimit valid coordinates for a spatial reference system and determine their resolution. It is possible that the domain extent is larger than the usable area of a coordinate system (a UTM zone, for example). A small domain extent gives you finer resolution coordinates over a smaller area. A larger domain extent lets you represent features over a larger geographic area but with coarser resolution.

Specified by:
getDomain in interface ISpatialReference
Parameters:
xMin - The xMin (out: use single element array)
xMax - The xMax (out: use single element array)
yMin - The yMin (out: use single element array)
yMax - The yMax (out: use single element array)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setDomain

public void setDomain(double xMin,
                      double xMax,
                      double yMin,
                      double yMax)
               throws java.io.IOException,
                      AutomationException
Description copied from interface: ISpatialReference
The XY domain extent.

Specified by:
setDomain in interface ISpatialReference
Parameters:
xMin - The xMin (in)
xMax - The xMax (in)
yMin - The yMin (in)
yMax - The yMax (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getZDomain

public void getZDomain(double[] outZMin,
                       double[] outZMax)
                throws java.io.IOException,
                       AutomationException
Description copied from interface: ISpatialReference
The Z domain extent.

Supported Platforms

Windows, Solaris, Linux

Description

An alternative method to the GetZFalseOriginAndUnits method. Returns the minimum and maximum allowed Z values for a spatial reference. Use GetZFalseOriginAndUnits to obtain the Z precision (1/resolution) value.

Specified by:
getZDomain in interface ISpatialReference
Parameters:
outZMin - The outZMin (out: use single element array)
outZMax - The outZMax (out: use single element array)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setZDomain

public void setZDomain(double inZMin,
                       double inZMax)
                throws java.io.IOException,
                       AutomationException
Description copied from interface: ISpatialReference
The Z domain extent.

Specified by:
setZDomain in interface ISpatialReference
Parameters:
inZMin - The inZMin (in)
inZMax - The inZMax (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getMDomain

public void getMDomain(double[] outMMin,
                       double[] outMMax)
                throws java.io.IOException,
                       AutomationException
Description copied from interface: ISpatialReference
The measure domain extent.

Supported Platforms

Windows, Solaris, Linux

Description

An alternative method to the GetMFalseOriginAndUnits method. Returns the minimum and maximum allowed measure values for a spatial reference. Use GetMFalseOriginAndUnits to obtain the M precision (1/resolution) value.

Specified by:
getMDomain in interface ISpatialReference
Parameters:
outMMin - The outMMin (out: use single element array)
outMMax - The outMMax (out: use single element array)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

setMDomain

public void setMDomain(double inMMin,
                       double inMMax)
                throws java.io.IOException,
                       AutomationException
Description copied from interface: ISpatialReference
The measure domain extent.

Specified by:
setMDomain in interface ISpatialReference
Parameters:
inMMin - The inMMin (in)
inMMax - The inMMax (in)
Throws:
AutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.

getZCoordinateUnit

public ILinearUnit getZCoordinateUnit()
                               throws java.io.IOException,
                                      AutomationException
Description copied from interface: ISpatialReference
The unit for the Z coordinate.

Supported Platforms

Windows, Solaris, Linux

Remarks

ISpatialReference::ZCoordinateUnit should no longer be used in favor of ISpatialReference3::VerticalCoordinateSystem 

There is now an entire Vertical Coordinate System available for your convenience. Using ISpatialReference3::VerticalCoordinateSystem has several benefits including allowing the user to choose a datum, positive or negative direction for the values of Z, and a vertical shift to the Z values.

 

Specified by:
getZCoordinateUnit in interface ISpatialReference
Returns:
A reference to a com.esri.arcgis.geometry.ILinearUnit
Throws:
AutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.

setZCoordinateUnit

public void setZCoordinateUnit(ILinearUnit zunit)
                        throws java.io.IOException,
                               AutomationException
Description copied from interface: ISpatialReference
The unit for the Z coordinate.

Supported Platforms

Windows, Solaris, Linux

Specified by:
setZCoordinateUnit in interface ISpatialReference
Parameters:
zunit - A reference to a com.esri.arcgis.geometry.ILinearUnit (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

changed

public void changed()
             throws java.io.IOException,
                    AutomationException
Description copied from interface: ISpatialReference
Notify this object that some of its parts have changed (parameter values, z unit, etc.).

Supported Platforms

Windows, Solaris, Linux

Specified by:
changed in interface ISpatialReference
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.