com.esri.arcgis.controls
Class ILicenseControlDefaultProxy

java.lang.Object
  extended by com.esri.arcgis.interop.Dispatch
      extended by com.esri.arcgis.controls.ILicenseControlDefaultProxy
All Implemented Interfaces:
ILicenseControlDefault, Externalizable, Serializable

public class ILicenseControlDefaultProxy
extends com.esri.arcgis.interop.Dispatch
implements ILicenseControlDefault, Serializable

Provides access to members that control the LicenseControl.

Description

The ILicenseControlDefault interface is the default dispatch interface that most development environments will automatically expose. For example, placing the LicenseControl in a container will typically generate an object called LicenseControl1. The properties and methods available directly on this object correspond to this interface, together with container specific properties and methods.

The ILicenseControlDefault interface is a 'pure' dispatch interface, so can be extended with new properties and methods at future releases of ArcGIS. The methods and properties are identical to the highest numbered main interface on the LicenseControl. For example, ILicenseControlDefault is equivalent to ILicenseControl, but at future releases this could become ILicenseControl2. By using the ILicenseControlDefault interface you are guaranteed to always have access to the latest LicenseControl.

There is a small performance overhead in making calls through to a pure dispatch interface, but to avoid this you can QI to a specific interface. In some development environments it is not possible to QI directly on the control to other COM interfaces, because the control is contained within a wrapper object. Use the Object property to get the real control before performing the QI.

Product Availability

Available with ArcGIS Engine.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class com.esri.arcgis.interop.Dispatch
DISPATCH_METHOD, DISPATCH_PROPERTYGET, DISPATCH_PROPERTYPUT, DISPATCH_PROPERTYPUTREF, E
 
Constructor Summary
  ILicenseControlDefaultProxy()
           
  ILicenseControlDefaultProxy(Object obj)
           
protected ILicenseControlDefaultProxy(Object obj, String iid)
           
 
Method Summary
 void aboutBox()
          Displays a dialog of information about the LicenseControl.
 void addListener(String iidStr, Object theListener, Object theSource)
           
 String getLicenseAvailability(int option)
          A Description of the availability of the licenses either all licenses or just those specified in the LicenseControls property page.
 int getStatus()
          The status of the LicenseControl initialization.
 String getSummary()
          A summary of the status of the LicenseControl initialization.
 void readExternal(ObjectInput in)
           
 void removeListener(String iidStr, Object theListener)
           
 void showStatusDialog(int hWndParent, int option, Object windowTitle, Object heading)
          Shows a dialog displaying the LicenseControl status and the current license availability.
 void writeExternal(ObjectOutput out)
           
 
Methods inherited from class com.esri.arcgis.interop.Dispatch
bindUsingMoniker, constructVtblPosTable, convertToNative, cookieForListener, createDispatch, createObjrefMonikerDisplayName, equals, getActiveObject, getActiveObject, getDefaultProperty, getDispatchIdOfName, getLastErrorCode, getMtsObjectContext, getObjRef, getPropertyByName, getPropertyByName, getVtblPos, hashCode, initDispatch, invoke, invokeMethodByName, invokeMethodByName, invokeMethodByName, invokePropertyGetByName, invokePropertyPutByName, invokePropertyPutByRefByName, isNativeMode, isObjRef, queryInterface, release, setNativeMode, setPropertyByName, toString, vtblInvoke
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ILicenseControlDefaultProxy

public ILicenseControlDefaultProxy()

ILicenseControlDefaultProxy

public ILicenseControlDefaultProxy(Object obj)
                            throws IOException
Throws:
IOException

ILicenseControlDefaultProxy

protected ILicenseControlDefaultProxy(Object obj,
                                      String iid)
                               throws IOException
Throws:
IOException
Method Detail

addListener

public void addListener(String iidStr,
                        Object theListener,
                        Object theSource)
                 throws IOException
Overrides:
addListener in class com.esri.arcgis.interop.Dispatch
Throws:
IOException

removeListener

public void removeListener(String iidStr,
                           Object theListener)
                    throws IOException
Overrides:
removeListener in class com.esri.arcgis.interop.Dispatch
Throws:
IOException

aboutBox

public void aboutBox()
              throws IOException,
                     AutomationException
Displays a dialog of information about the LicenseControl.

Description

The AboutBox method causes a modal dialog box to display on top of the LicenseControl, containing information about the version and creation date of the LicenseControl as well as listing relevant legal and copyright information from ESRI.

Product Availability

Available with ArcGIS Engine.

Specified by:
aboutBox in interface ILicenseControlDefault
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getStatus

public int getStatus()
              throws IOException,
                     AutomationException
The status of the LicenseControl initialization.

Description

Returns the Status of the LicenseControl when it initially tried to initilaize the application. If license initailization was successful the Status will return esriLicenseCheckedOut.

Remarks

If no product licenses were checked in the LicenseControl property pages, the Status returns esriLicenseFailure.

Product Availability

Available with ArcGIS Engine.

Specified by:
getStatus in interface ILicenseControlDefault
Returns:
A com.esri.arcgis.system.esriLicenseStatus constant
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getSummary

public String getSummary()
                  throws IOException,
                         AutomationException
A summary of the status of the LicenseControl initialization.

Description

Returns a summary of the license status after the LicenseControl has tried to initialize the application with a license. Use the Summary property when license initialization fails, to give information to the user on the nature of the failure, before programmatically shutting down the application.

The possible descriptions returned from the Summary property are as follows:
- "Successful license initialization."
- "No licenses were requested."
- "Failed to initialize license, required products are not available."
- "Failed to initialize license, required extensions are not available."
- "Failed to initialize product license."
- "Failed to checkout extension license."

Remarks

The default behaviour of the LicenseControl is to allow the developer to programmatically check for and shutdown an application when license initialization fails. To override this behaviour so the LicenseControl automatically shuts down an application when license initialization fails, check the "Shutdown this application if the selected licenses are not available" check box in the property pages of the LicenseControl.

Product Availability

Available with ArcGIS Engine.

Specified by:
getSummary in interface ILicenseControlDefault
Returns:
The returnValue
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getLicenseAvailability

public String getLicenseAvailability(int option)
                              throws IOException,
                                     AutomationException
A Description of the availability of the licenses either all licenses or just those specified in the LicenseControls property page.

Product Availability

Available with ArcGIS Engine.

Specified by:
getLicenseAvailability in interface ILicenseControlDefault
Parameters:
option - A com.esri.arcgis.controls.esriLicenseStatusOptions constant (in, optional, pass 1 if not required)
Returns:
The returnValue
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

showStatusDialog

public void showStatusDialog(int hWndParent,
                             int option,
                             Object windowTitle,
                             Object heading)
                      throws IOException,
                             AutomationException
Shows a dialog displaying the LicenseControl status and the current license availability.

Description

Opens a modal dialog specifying the current availability of the specified product and extension licenses. Use the ShowStatusDialog method when license initialization fails, to give information to the user on the nature of the failure, before programmatically shutting down the application. Alternatively, use the Status, Summary and LicenseAvailability members to create your own dialog.

esriLicenseStatusRequested returns the availability of those product and extension licenses checked in the LicenseControl property pages. Use this option when license initialization fails, to give information to the user on the nature of the failure, before programmatically shutting down the application.

esriLicenseStatusAll returns the availability of all product and extension licenses. Use this option when debugging.

By default the modal dialog will have a window title of "License Status" and a heading of "Requested License Status".

Remarks

The default behaviour of the LicenseControl is to allow the developer to programmatically check for and shutdown an application when license initialization fails. To override this behaviour so the LicenseControl automatically shuts down an application when license initialization fails, check the "Shutdown this application if the selected licenses are not available" check box in the property pages of the LicenseControl.

Product Availability

Available with ArcGIS Engine.

Specified by:
showStatusDialog in interface ILicenseControlDefault
Parameters:
hWndParent - The hWndParent (in, optional, pass 0 if not required)
option - A com.esri.arcgis.controls.esriLicenseStatusOptions constant (in, optional, pass 1 if not required)
windowTitle - A Variant (in, optional, pass null if not required)
heading - A Variant (in, optional, pass null if not required)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

writeExternal

public void writeExternal(ObjectOutput out)
                   throws IOException
Specified by:
writeExternal in interface Externalizable
Overrides:
writeExternal in class com.esri.arcgis.interop.Dispatch
Throws:
IOException

readExternal

public void readExternal(ObjectInput in)
                  throws IOException,
                         ClassNotFoundException
Specified by:
readExternal in interface Externalizable
Overrides:
readExternal in class com.esri.arcgis.interop.Dispatch
Throws:
IOException
ClassNotFoundException