com.esri.arcgis.controls
Class HookHelper

java.lang.Object
  extended by com.esri.arcgis.controls.HookHelper
All Implemented Interfaces:
IHookActions, IHookHelper, IConnectionPointContainer, com.esri.arcgis.interop.RemoteObjRef, ISupportErrorInfo, java.io.Serializable

public class HookHelper
extends java.lang.Object
implements com.esri.arcgis.interop.RemoteObjRef, IHookHelper, IConnectionPointContainer, ISupportErrorInfo, IHookActions

COM Class 'HookHelper'. Generated 3/19/2015 1:20:48 PM from 'C:\ArcGIS\COM\esriControls.olb'

Description 'Helps commands work with the MapControl, PageLayoutControl, ArcMap, custom controls and applications.' Generator Options: PromptForTypeLibraries = False ClashPrefix = esri_ LowerCaseMemberNames = True IDispatchOnly = False RetryOnReject = False AwtForOcxs = True ArraysAsObjects = False DontRenameSameMethods = False ImplementConflictingInterfaces = True ReuseMethods = True RenameConflictingInterfaceMethods = True GenBeanInfo = True GenerateJavadoc =

See Also:
Serialized Form

Field Summary
 
Fields inherited from interface com.esri.arcgis.controls.IHookHelper
IID, IID128903ab_6017_47fd_81be_0109f61e9c09, xxDummy
 
Fields inherited from interface com.esri.arcgis.display.IConnectionPointContainer
IID, IIDb196b284_bab4_101a_b69c_00aa00341d07, xxDummy
 
Fields inherited from interface com.esri.arcgis.system.ISupportErrorInfo
IID, IIDdf0b3d60_548f_101b_8e65_08002b2bd119, xxDummy
 
Fields inherited from interface com.esri.arcgis.controls.IHookActions
IID, IIDc81e082f_eaf8_4fd5_b309_00f75780f8ad, xxDummy
 
Constructor Summary
HookHelper()
          Constructs a HookHelper using ArcGIS Engine.
HookHelper(java.lang.Object obj)
          Deprecated. As of ArcGIS 9.2, replaced by normal Java casts.
HookHelper theHookHelper = (HookHelper) obj;
 
Method Summary
 void addIHookHelperEventsListener(IHookHelperEvents theListener)
          addIHookHelperEventsListener.
 void doAction(java.lang.Object pUnknown, int action)
          Perform the action on the object.
 void doActionOnMultiple(IArray pArray, int action)
          Perform the action on the array of objects.
 void doActionWithName(java.lang.Object pUnknown, java.lang.String name, int action)
          Perform the action on the object using the name.
 void doActionWithNameOnMultiple(IArray pArray, IStringArray pNamesArray, int action)
          Perform the action on the array of objects using the array of names.
 void enumConnectionPoints(IEnumConnectionPoints[] ppEnum)
          enumConnectionPoints
 boolean equals(java.lang.Object o)
          Compare this object with another
 void findConnectionPoint(GUID riid, IConnectionPoint[] ppCP)
          findConnectionPoint
 IActiveView getActiveView()
          Active view of hooked control or application.
static java.lang.String getClsid()
          getClsid.
 IMap getFocusMap()
          Focus map of hooked control or application.
 java.lang.Object getHook()
          Hook object that should be the same as the hook object passed in ICommand::OnCreate.
 com.esri.arcgis.interop.Dispatch getJintegraDispatch()
          Deprecated. Internal use only.
 IOperationStack getOperationStack()
          Operation stack of hooked control or application used for undo/redo operations.
 IPageLayout getPageLayout()
          Page layout of hooked control or application.
 int hashCode()
          the hashcode for this object
 void interfaceSupportsErrorInfo(GUID riid)
          interfaceSupportsErrorInfo
 boolean isActionSupported(java.lang.Object pUnknown, int action)
          Indicates whether the specified action can be performed on the object.
 boolean isActionSupportedOnMultiple(IArray pArray, int action)
          Indicates whether the specified action can be performed on the array of objects.
 void release()
          Release a HookHelper.
 void removeIHookHelperEventsListener(IHookHelperEvents theListener)
          removeIHookHelperEventsListener.
 void setHookByRef(java.lang.Object ppHook)
          Hook object that should be the same as the hook object passed in ICommand::OnCreate.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HookHelper

public HookHelper()
           throws java.io.IOException,
                  java.net.UnknownHostException
Constructs a HookHelper using ArcGIS Engine.

Throws:
java.io.IOException - if there are interop problems
java.net.UnknownHostException - if there are interop problems

HookHelper

public HookHelper(java.lang.Object obj)
           throws java.io.IOException
Deprecated. As of ArcGIS 9.2, replaced by normal Java casts.
HookHelper theHookHelper = (HookHelper) obj;

Construct a HookHelper using a reference to such an object returned from ArcGIS Engine or Server. This is semantically equivalent to casting obj to HookHelper.

Parameters:
obj - an object returned from ArcGIS Engine or Server
Throws:
java.io.IOException - if there are interop problems
Method Detail

getClsid

public static java.lang.String getClsid()
getClsid.


equals

public boolean equals(java.lang.Object o)
Compare this object with another

Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
the hashcode for this object

Overrides:
hashCode in class java.lang.Object

getJintegraDispatch

public com.esri.arcgis.interop.Dispatch getJintegraDispatch()
Deprecated. Internal use only.

Specified by:
getJintegraDispatch in interface com.esri.arcgis.interop.RemoteObjRef

addIHookHelperEventsListener

public void addIHookHelperEventsListener(IHookHelperEvents theListener)
                                  throws java.io.IOException
addIHookHelperEventsListener. Listen to events generated by this class.

Parameters:
theListener - An object that implements the com.esri.arcgis.controls.IHookHelperEvents interface.
Throws:
java.io.IOException - If there are communications problems.

removeIHookHelperEventsListener

public void removeIHookHelperEventsListener(IHookHelperEvents theListener)
                                     throws java.io.IOException
removeIHookHelperEventsListener. Stop listening to events generated by this class.

Parameters:
theListener - An object that implements the com.esri.arcgis.controls.IHookHelperEvents interface.
Throws:
java.io.IOException - If there are communications problems.

release

public void release()
Release a HookHelper.

Specified by:
release in interface com.esri.arcgis.interop.RemoteObjRef

setHookByRef

public void setHookByRef(java.lang.Object ppHook)
                  throws java.io.IOException,
                         AutomationException
Hook object that should be the same as the hook object passed in ICommand::OnCreate.

Specified by:
setHookByRef in interface IHookHelper
Parameters:
ppHook - A reference to another Automation Object (IDispatch) (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getHook

public java.lang.Object getHook()
                         throws java.io.IOException,
                                AutomationException
Hook object that should be the same as the hook object passed in ICommand::OnCreate.

Specified by:
getHook in interface IHookHelper
Returns:
A reference to another Automation Object (IDispatch)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getActiveView

public IActiveView getActiveView()
                          throws java.io.IOException,
                                 AutomationException
Active view of hooked control or application.

Specified by:
getActiveView in interface IHookHelper
Returns:
A reference to a com.esri.arcgis.carto.IActiveView
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getPageLayout

public IPageLayout getPageLayout()
                          throws java.io.IOException,
                                 AutomationException
Page layout of hooked control or application.

Specified by:
getPageLayout in interface IHookHelper
Returns:
A reference to a com.esri.arcgis.carto.IPageLayout
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getFocusMap

public IMap getFocusMap()
                 throws java.io.IOException,
                        AutomationException
Focus map of hooked control or application.

Specified by:
getFocusMap in interface IHookHelper
Returns:
A reference to a com.esri.arcgis.carto.IMap
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getOperationStack

public IOperationStack getOperationStack()
                                  throws java.io.IOException,
                                         AutomationException
Operation stack of hooked control or application used for undo/redo operations.

Specified by:
getOperationStack in interface IHookHelper
Returns:
A reference to a com.esri.arcgis.systemUI.IOperationStack
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

enumConnectionPoints

public void enumConnectionPoints(IEnumConnectionPoints[] ppEnum)
                          throws java.io.IOException,
                                 AutomationException
enumConnectionPoints

Specified by:
enumConnectionPoints in interface IConnectionPointContainer
Parameters:
ppEnum - A reference to a com.esri.arcgis.display.IEnumConnectionPoints (out: use single element array)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

findConnectionPoint

public void findConnectionPoint(GUID riid,
                                IConnectionPoint[] ppCP)
                         throws java.io.IOException,
                                AutomationException
findConnectionPoint

Specified by:
findConnectionPoint in interface IConnectionPointContainer
Parameters:
riid - A Structure: com.esri.arcgis.support.ms.stdole.GUID (in)
ppCP - A reference to a com.esri.arcgis.display.IConnectionPoint (out: use single element array)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

interfaceSupportsErrorInfo

public void interfaceSupportsErrorInfo(GUID riid)
                                throws java.io.IOException,
                                       AutomationException
interfaceSupportsErrorInfo

Specified by:
interfaceSupportsErrorInfo in interface ISupportErrorInfo
Parameters:
riid - A Structure: com.esri.arcgis.support.ms.stdole.GUID (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isActionSupported

public boolean isActionSupported(java.lang.Object pUnknown,
                                 int action)
                          throws java.io.IOException,
                                 AutomationException
Indicates whether the specified action can be performed on the object.

Specified by:
isActionSupported in interface IHookActions
Parameters:
pUnknown - A reference to another Object (IUnknown) (in)
action - A com.esri.arcgis.controls.esriHookActions constant (in)
Returns:
The pIsEnable
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

isActionSupportedOnMultiple

public boolean isActionSupportedOnMultiple(IArray pArray,
                                           int action)
                                    throws java.io.IOException,
                                           AutomationException
Indicates whether the specified action can be performed on the array of objects.

Specified by:
isActionSupportedOnMultiple in interface IHookActions
Parameters:
pArray - A reference to a com.esri.arcgis.system.IArray (in)
action - A com.esri.arcgis.controls.esriHookActions constant (in)
Returns:
The pIsEnable
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

doAction

public void doAction(java.lang.Object pUnknown,
                     int action)
              throws java.io.IOException,
                     AutomationException
Perform the action on the object.

Specified by:
doAction in interface IHookActions
Parameters:
pUnknown - A reference to another Object (IUnknown) (in)
action - A com.esri.arcgis.controls.esriHookActions constant (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

doActionWithName

public void doActionWithName(java.lang.Object pUnknown,
                             java.lang.String name,
                             int action)
                      throws java.io.IOException,
                             AutomationException
Perform the action on the object using the name.

Specified by:
doActionWithName in interface IHookActions
Parameters:
pUnknown - A reference to another Object (IUnknown) (in)
name - The name (in)
action - A com.esri.arcgis.controls.esriHookActions constant (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

doActionOnMultiple

public void doActionOnMultiple(IArray pArray,
                               int action)
                        throws java.io.IOException,
                               AutomationException
Perform the action on the array of objects.

Specified by:
doActionOnMultiple in interface IHookActions
Parameters:
pArray - A reference to a com.esri.arcgis.system.IArray (in)
action - A com.esri.arcgis.controls.esriHookActions constant (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

doActionWithNameOnMultiple

public void doActionWithNameOnMultiple(IArray pArray,
                                       IStringArray pNamesArray,
                                       int action)
                                throws java.io.IOException,
                                       AutomationException
Perform the action on the array of objects using the array of names.

Specified by:
doActionWithNameOnMultiple in interface IHookActions
Parameters:
pArray - A reference to a com.esri.arcgis.system.IArray (in)
pNamesArray - A reference to a com.esri.arcgis.system.IStringArray (in)
action - A com.esri.arcgis.controls.esriHookActions constant (in)
Throws:
java.io.IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.