18.04.2015 Views

ArcGIS Engine Developer Guide

ArcGIS Engine Developer Guide

ArcGIS Engine Developer Guide

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

APPLICATION DEVELOPMENT AND LICENSE INITIALIZATION<br />

Step 5: Shutdown<br />

5. The final step in the initialization process is ensuring that the licenses are<br />

released when the application is shut down.<br />

EXAMPLE C—MINIMUM LICENSE IS ARCGIS ENGINE. OPTIONAL<br />

NETWORK FUNCTIONALITY AVAILABLE<br />

Once again the example application requires a minimum of an <strong>ArcGIS</strong> <strong>Engine</strong><br />

license. The developer has decided that if an <strong>ArcGIS</strong> <strong>Engine</strong> license is not available,<br />

the application could run with an ArcView, ArcEditor, or ArcInfo license<br />

instead. Similar to the previous examples, this application also includes extension<br />

functionality—Network—but, in this case, the extension is not required simply<br />

to run the application; instead, it enables additional functionality. As such the<br />

Network extension will be checked out dynamically during the use of the application<br />

rather than at application startup.<br />

Once again the application will first attempt to initialize against the <strong>ArcGIS</strong><br />

<strong>Engine</strong> product license. If that fails, it will make additional attempts to initialize<br />

against an ArcView license, an ArcEditor license, and if still unsuccessful, the<br />

application will finally attempt to initialize against the ArcInfo product license.<br />

The following sections outline the steps taken to initialize the application with a<br />

license.<br />

Step 1: Check product license<br />

availability<br />

Step 2: Check extension license<br />

availability<br />

Step 3: Initialize the application<br />

Step 4: Check extensions in and<br />

out<br />

Step 5: Shutdown<br />

Attempting initialization with the <strong>ArcGIS</strong> <strong>Engine</strong> product license<br />

As indicated above, to run successfully the application requires at minimum an<br />

<strong>ArcGIS</strong> <strong>Engine</strong> product license. While Network functionality is available within<br />

the application, its extension license can be checked out when needed rather than<br />

for the duration of the session. The application’s first attempt at initialization<br />

should be against this minimal level of product licensing. The application’s attempts<br />

at initialization follow the process discussed earlier.<br />

1. Check whether an <strong>ArcGIS</strong> <strong>Engine</strong> product license is available. If yes, proceed<br />

to the next step in the initialization process. If not, discontinue this attempt<br />

and restart initialization with any secondary level of allowable product licensing.<br />

2. Check whether a Network extension license is available with the <strong>ArcGIS</strong><br />

<strong>Engine</strong> product license. If yes, proceed to the next step in the initialization<br />

process. If not, proceed to the next step in the initialization process.<br />

3. Check out the <strong>ArcGIS</strong> <strong>Engine</strong> product license by initializing the application.<br />

If the license checked out, proceed to the next step in the initialization process.<br />

If the license failed to check out, discontinue this attempt and restart<br />

initialization with any secondary level of allowable product licensing.<br />

Since this application dynamically checks out the Network extension, this step<br />

is not performed at this time. Instead, the license will be checked out during<br />

usage of Network functionality. See the section ‘Using Network functionality’<br />

below for details on this process.<br />

In this example, no licenses beyond the <strong>ArcGIS</strong> <strong>Engine</strong> product license need<br />

to be checked out, so if that license checked out, the application has been<br />

successfully configured with licenses.<br />

4. The final step in the initialization process is ensuring that the licenses are<br />

released when the application is shut down.<br />

270 • <strong>ArcGIS</strong> <strong>Engine</strong> <strong>Developer</strong> <strong>Guide</strong>

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!