com.esri.arcgis.geometry
Class IRayProxy

java.lang.Object
  extended bycom.esri.arcgis.interop.Dispatch
      extended bycom.esri.arcgis.geometry.IGeometryProxy
          extended bycom.esri.arcgis.geometry.IRayProxy
All Implemented Interfaces:
java.io.Externalizable, IGeometry, IRay, java.io.Serializable

public class IRayProxy
extends IGeometryProxy
implements IRay, java.io.Serializable

Provides access to 3D Ray properties and methods. A ray has one endpoint (its origin) and continues infinitely in one direction.

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
  IRayProxy()
          For internal use only
  IRayProxy(java.lang.Object obj)
           
protected IRayProxy(java.lang.Object obj, java.lang.String iid)
           
  IRayProxy(java.lang.String CLSID, java.lang.String host, AuthInfo authInfo)
           
protected IRayProxy(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.
 IEnumIntersection getEnumIntersect(IGeometry targetGeometry)
          Not implemented at this release.
 IPoint getOrigin()
          The origin point of the ray.
 IPoint getPointAtDistance(double distance)
          Constructs a point at a distance along the ray.
 IVector3D getVector()
          The direction vector of the ray.
 void intersect(IGeometry targetGeometry, IPointCollection intersectionPoints)
          Returns a point collection containing all points of intersection, in order along the ray.
 boolean intersects(IGeometry targetGeometry)
          Indicates if the ray intersects the target geometry.
 void queryFirstIntersection(IGeometry targetGeometry, IPoint intersectionPoint)
          Returns the first point of intersection between the ray and the target geometry.
 void queryOrigin(IPoint vectorOrigin)
          Sets a point equal to the ray's origin.
 void queryPointAtDistance(double distance, IPoint point)
          Queries a point at a distance along the ray.
 void queryVector(IVector3D directionVector)
          Sets a vector equal to a unit vector with the same direction as the ray.
 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 setOrigin(IPoint vectorOrigin)
          The origin point of the ray.
 void setVector(IVector3D directionVector)
          The direction vector of the ray.
 
Methods inherited from class com.esri.arcgis.geometry.IGeometryProxy
geoNormalize, geoNormalizeFromLongitude, getDimension, getEnvelope, getGeometryType, getSpatialReference, isEmpty, project, queryEnvelope, setEmpty, setSpatialReferenceByRef, snapToSpatialReference
 
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.IGeometry
geoNormalize, geoNormalizeFromLongitude, getDimension, getEnvelope, getGeometryType, getSpatialReference, isEmpty, project, queryEnvelope, setEmpty, setSpatialReferenceByRef, snapToSpatialReference
 

Field Detail

targetClass

public static final java.lang.Class targetClass
Constructor Detail

IRayProxy

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

IRayProxy

public IRayProxy()
For internal use only


IRayProxy

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

IRayProxy

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

IRayProxy

protected IRayProxy(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 IGeometryProxy
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 IGeometryProxy
Throws:
java.io.IOException

queryOrigin

public void queryOrigin(IPoint vectorOrigin)
                 throws java.io.IOException,
                        AutomationException
Description copied from interface: IRay
Sets a point equal to the ray's origin.

Supported Platforms

Windows, Solaris, Linux

Description

Returns the Origin of the Ray into the input Point.

Remarks

Note: The output geometry must be co-created prior to the query. The output geometry is not co-created by the method; it is populated. This can be used in performance critical situations. For example, creating the geometry only once outside a loop and use the query method could improve performance.

Ray QueryOrigin Example

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

getOrigin

public IPoint getOrigin()
                 throws java.io.IOException,
                        AutomationException
Description copied from interface: IRay
The origin point of the ray.

Supported Platforms

Windows, Solaris, Linux

Description

Returns and sets the Origin of the Ray.  The Origin is the starting Point from which the Ray infinitely extends in the direction of its vector.

Remarks

 

Ray Origin Example

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

setOrigin

public void setOrigin(IPoint vectorOrigin)
               throws java.io.IOException,
                      AutomationException
Description copied from interface: IRay
The origin point of the ray.

Supported Platforms

Windows, Solaris, Linux

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

queryVector

public void queryVector(IVector3D directionVector)
                 throws java.io.IOException,
                        AutomationException
Description copied from interface: IRay
Sets a vector equal to a unit vector with the same direction as the ray.

Supported Platforms

Windows, Solaris, Linux

Description

Returns the Vector3D of the Ray.  The Vector3D determines the direction the Ray extends from its Origin.  The Vector of a Ray is always Normalized to a unit vector.

Remarks

 

Ray QueryVector Example

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

getVector

public IVector3D getVector()
                    throws java.io.IOException,
                           AutomationException
Description copied from interface: IRay
The direction vector of the ray.

Supported Platforms

Windows, Solaris, Linux

Description

Returns and sets the Vector3D of the Ray.  The Vector3D determines the direction the Ray extends from its Origin.  The Vector of a Ray is always Normalized to a unit vector.

Remarks

 

Ray Vector Example

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

setVector

public void setVector(IVector3D directionVector)
               throws java.io.IOException,
                      AutomationException
Description copied from interface: IRay
The direction vector of the ray.

Supported Platforms

Windows, Solaris, Linux

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

queryPointAtDistance

public void queryPointAtDistance(double distance,
                                 IPoint point)
                          throws java.io.IOException,
                                 AutomationException
Description copied from interface: IRay
Queries a point at a distance along the ray.

Supported Platforms

Windows, Solaris, Linux

Specified by:
queryPointAtDistance in interface IRay
Parameters:
distance - The distance (in)
point - A reference to a com.esri.arcgis.geometry.IPoint (in)
Throws:
AutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.

getPointAtDistance

public IPoint getPointAtDistance(double distance)
                          throws java.io.IOException,
                                 AutomationException
Description copied from interface: IRay
Constructs a point at a distance along the ray.

Supported Platforms

Windows, Solaris, Linux

Specified by:
getPointAtDistance in interface IRay
Parameters:
distance - The distance (in)
Returns:
A reference to a com.esri.arcgis.geometry.IPoint
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

intersects

public boolean intersects(IGeometry targetGeometry)
                   throws java.io.IOException,
                          AutomationException
Description copied from interface: IRay
Indicates if the ray intersects the target geometry.

Supported Platforms

Windows, Solaris, Linux

Specified by:
intersects in interface IRay
Parameters:
targetGeometry - A reference to a com.esri.arcgis.geometry.IGeometry (in)
Returns:
The intersectsTarget
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

queryFirstIntersection

public void queryFirstIntersection(IGeometry targetGeometry,
                                   IPoint intersectionPoint)
                            throws java.io.IOException,
                                   AutomationException
Description copied from interface: IRay
Returns the first point of intersection between the ray and the target geometry. The point is set empty if there is no intersection.

Supported Platforms

Windows, Solaris, Linux

Specified by:
queryFirstIntersection in interface IRay
Parameters:
targetGeometry - A reference to a com.esri.arcgis.geometry.IGeometry (in)
intersectionPoint - A reference to a com.esri.arcgis.geometry.IPoint (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

intersect

public void intersect(IGeometry targetGeometry,
                      IPointCollection intersectionPoints)
               throws java.io.IOException,
                      AutomationException
Description copied from interface: IRay
Returns a point collection containing all points of intersection, in order along the ray.

Supported Platforms

Windows, Solaris, Linux

Specified by:
intersect in interface IRay
Parameters:
targetGeometry - A reference to a com.esri.arcgis.geometry.IGeometry (in)
intersectionPoints - A reference to a com.esri.arcgis.geometry.IPointCollection (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getEnumIntersect

public IEnumIntersection getEnumIntersect(IGeometry targetGeometry)
                                   throws java.io.IOException,
                                          AutomationException
Description copied from interface: IRay
Not implemented at this release.

Supported Platforms

Windows, Solaris, Linux

Specified by:
getEnumIntersect in interface IRay
Parameters:
targetGeometry - A reference to a com.esri.arcgis.geometry.IGeometry (in)
Returns:
A reference to a com.esri.arcgis.geometry.IEnumIntersection
Throws:
AutomationException - If the ArcObject component throws an exception.
java.io.IOException - If there are interop problems.