⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 application_licensing.htm

📁 acis说明文档
💻 HTM
📖 第 1 页 / 共 3 页
字号:
<li class="toclevel-2"><a href="#Unlock_Function"><span class="tocnumber">4.1</span> <span class="toctext">Unlock Function</span></a></li></ul></li><li class="toclevel-1"><a href="#Procedure_for_Using_the_Key_to_Unlock_Spatial_Products"><span class="tocnumber">5</span> <span class="toctext">Procedure for Using the Key to Unlock Spatial Products</span></a><ul><li class="toclevel-2"><a href="#Embedding_the_Key_into_Your_Application"><span class="tocnumber">5.1</span> <span class="toctext">Embedding the Key into Your Application</span></a></li></ul></li><li class="toclevel-1"><a href="#Troubleshooting_When_the_Unlock_Process_Fails"><span class="tocnumber">6</span> <span class="toctext">Troubleshooting When the Unlock Process Fails</span></a></li></ul></li></ul></td></tr></table><script type="text/javascript"> if (window.showTocToggle) { var tocShowText = "show"; var tocHideText = "hide"; showTocToggle(); } </script><a name="Typical_scenarios_for_obtaining_a_new_Application_Key"></a><h1> <span class="mw-headline"> Typical scenarios for obtaining a new Application Key </span></h1><a name="New_Application_Key_for_Next_major_release"></a><h3> <span class="mw-headline"> New Application Key for Next major release </span></h3><p>Spatial releases the next major version of its software. You want to upgrade your Spatial products to the next version. Your existing application key is bound to the earlier version, therefore, you must obtain a new application key. (Service Pack releases continue to use the same application key; thus, obtaining a new application key is not required.)</p><a name="New_Application_Key_after_Evaluating_Spatial_Products"></a><h3> <span class="mw-headline"> New Application Key after Evaluating Spatial Products </span></h3><p>Under an evaluation license agreement you obtained an Evaluation application key in the past to evaluate Spatial products in your application. You have now decided to integrate Spatial products as a permanent choice for your application and to distribute your application to your end users. You contact your Spatial sales representative to have your license agreement changed to production. Hence, you must obtain a Production application key.</p><a name="New_Application_Key_when_changing_number_of_products_in_use"></a><h3> <span class="mw-headline"> New Application Key when changing number of products in use </span></h3><p>You obtained an application key for three Spatial products. You now wish to discontinue using one of those products, and in its place, begin using another Spatial product. You must obtain an application key that will be bound to the new product as well as the other two Spatial products you still plan to use.</p><a name="Sample_Application_Key"></a><h1> <span class="mw-headline"> Sample Application Key </span></h1><p>The application key comprises of a key string and a license-specific function provided in a C++ file from the Spatial Licensing Web Site. Together, the key string and function unlock Spatial products. When you obtain your application license key, the Spatial Licensing Web Site also returns specific data required by the Spatial registration function, discussed later in this section. From the same Web page, you are requested to download the C++ file which, again, contains the application key string and the license-specific function.</p><p>The contents of the C++ file are represented as follows:</p><pre class="source-cpp"><span class="kw2">#include</span> <span class="st0">&quot;spa_unlock_result.hxx&quot;</span><span class="kw2">#include</span> <span class="st0">&quot;spa_lic_err_gui.hxx&quot;</span>&nbsp;<span class="co1">// Customer ID:                 ABC111</span><span class="co1">// Customer Name:               ABC Company, Inc.</span><span class="co1">// Application Name:            ABC Application</span><span class="co1">// Licensed Spatial Products:</span><span class="co1">//    3D ACIS Modeler</span><span class="co1">//    3D ACIS Deformable Modeling</span><span class="co1">//    3D InterOp ACIS CATIA V4 Reader/Writer</span><span class="co1">// Spatial Product Version:     R17</span><span class="co1">// License Type:                Permanent</span><span class="co1">// Expiration Date:             N/A</span><span class="co1">// Application Registration:    Required</span><span class="co1">// License Key Index:           11</span><span class="co1">// License Key:</span><span class="co1">//    11111111000000001111111100000000111111110000000011111111</span><span class="co1">//    11111111000000001111111100000000111111110000</span><span class="co1">// Generation Date:             2006/06/27</span><span class="co1">//</span><span class="kw7">GLOBAL_PROC</span> <span class="kw4">void</span> unlock_spatial_products_11<span class="br0">&#40;</span><span class="br0">&#41;</span><span class="br0">&#123;</span>    <span class="kw4">const</span> <span class="kw4">char</span>* unlock_str =        <span class="st0">&quot;1111111100000000111111110000000011111111000000001111111100000000&quot;</span>        <span class="st0">&quot;1111111100000000111111110000000011111111000000001111111100000000&quot;</span>        <span class="st0">&quot;1111111100000000111111110000000011111111000000001111111100000000&quot;</span>        <span class="st0">&quot;1111111100000000111111110000000011111111000000001111111100000000&quot;</span>        <span class="st0">&quot;1111111100000000111111110000000011111111000000001111111100000000&quot;</span>        <span class="st0">&quot;1111111100000000111111110000000011111111000000001111111100000000&quot;</span>        <span class="st0">&quot;1111111100000000111111110000&quot;</span>;&nbsp;    <span class="kw7">spa_unlock_result</span> out = spa_unlock_products<span class="br0">&#40;</span> unlock_str <span class="br0">&#41;</span>;&nbsp;    <span class="co1">// NOTE: The Spatial error GUI is activated by default.  Customers</span>    <span class="co1">// are encouraged to replace the following with a customized solution.</span>    <span class="co1">//</span>    <span class="kw1">if</span> <span class="br0">&#40;</span> out.<span class="me1">get_state</span><span class="br0">&#40;</span><span class="br0">&#41;</span>&nbsp;!= SPA_UNLOCK_PASS <span class="br0">&#41;</span><span class="br0">&#123;</span>        spa_display_error_gui<span class="br0">&#40;</span> out <span class="br0">&#41;</span>;     <span class="br0">&#125;</span><span class="br0">&#125;</span></pre><p>If you use Spatial Registration, you must note the specific data required by the Spatial registration function before closing the Spatial Licensing Web page. These details are located near the end of the page. They include:</p><ul><li> Software Publisher</li><li> Application</li><li> Application Key Index</li><li> Spatial Software Version</li></ul><p>Use of these details is described in the <a href="/r18/index.php/Registration" title="Registration">Registration section</a>.</p><a name="Types_of_Application_Keys"></a><h1> <span class="mw-headline"> Types of Application Keys </span></h1><p>Spatial provides two types of application keys: "Production" and "Development". Most commonly, Spatial customers, who ship non-evaluation or development versions of Spatial products, obtain a "Production" application key, which is a permanent key.</p><p>The "Development" application key is automatically generated if any of the Spatial products bound to the application key are covered by an evaluation or development contract. The "Development" application key expires at the earliest expiration date of all relevant product contracts.</p><a name="Using_Your_Application_License_Key"></a><h1> <span class="mw-headline"> Using Your Application License Key </span></h1><p>Application keys must be obtained from the Spatial Licensing Web site located at www.spatial.com. A valid customer ID is required to access the site. The prompts are straightforward, and when completed, you will be presented with the option to download your C++ file containing your new application license key and other details to facilitate the registration process.</p><a name="Unlock_Function"></a><h2> <span class="mw-headline"> Unlock Function </span></h2><p>The C++ file contains code that you <i>must</i> embed into the end-user application. The C++ code returned from Spatial's Licensing Web site defines the function unlock_spatial_products_&lt;ALKIndex&gt;(). This function is responsible for calling the main licensing function   spa_unlock_products() (declared in license.hxx) with all the information needed to process the license key and unlock the licensed products.</p><p>The license function in the C++ file is represented as follows:</p><pre class="source-cpp"><span class="kw7">GLOBAL_PROC</span> <span class="kw4">void</span> unlock_spatial_products_11<span class="br0">&#40;</span><span class="br0">&#41;</span> <span class="br0">&#123;</span>     <span class="kw4">const</span> <span class="kw4">char</span>* unlock_str =         <span class="st0">&quot;1111111100000000111111110000000011111111000000001111111100000000&quot;</span>         <span class="st0">&quot;1111111100000000111111110000000011111111000000001111111100000000&quot;</span>         <span class="st0">&quot;1111111100000000111111110000000011111111000000001111111100000000&quot;</span>         <span class="st0">&quot;1111111100000000111111110000000011111111000000001111111100000000&quot;</span>         <span class="st0">&quot;1111111100000000111111110000000011111111000000001111111100000000&quot;</span>         <span class="st0">&quot;1111111100000000111111110000000011111111000000001111111100000000&quot;</span>         <span class="st0">&quot;1111111100000000111111110000&quot;</span>;&nbsp;     <span class="kw7">spa_unlock_result</span> out = spa_unlock_products<span class="br0">&#40;</span> unlock_str <span class="br0">&#41;</span>;&nbsp;     <span class="kw1">if</span> <span class="br0">&#40;</span> out.<span class="me1">get_state</span><span class="br0">&#40;</span><span class="br0">&#41;</span>&nbsp;!= SPA_UNLOCK_PASS <span class="br0">&#41;</span><span class="br0">&#123;</span>         spa_display_error_gui<span class="br0">&#40;</span> out <span class="br0">&#41;</span>;      <span class="br0">&#125;</span> <span class="br0">&#125;</span></pre><dl><dd><b>IMPORTANT!</b> - The definition of the string argument passed into <code>spa_unlock_products()</code> <i>must not</i> be edited. Any modification of this string results in a failure to unlock the licensed products.</dd></dl><a name="Procedure_for_Using_the_Key_to_Unlock_Spatial_Products"></a><h1> <span class="mw-headline"> Procedure for Using the Key to Unlock Spatial Products </span></h1><p>The process for using the key is as follows:</p><ol><li> Add the function to your application. Refer to the section #linkkey <i>Embedding the Key into Your Application</i> for details.</li><li> Compile your code.</li><li> Call the function at start-up time.</li></ol><p>You may modify the function, but do <i>not</i> modify the variable <i>unlock_str</i> or the call to   spa_unlock_products(). Modifying these lines invalidates your Application Key at runtime.</p><a name="Embedding_the_Key_into_Your_Application"></a><h2> <span class="mw-headline"> Embedding the Key into Your Application </span></h2><ol><li> Place the C++ code file in the same component where the end-user application is initialized.</li><li> Forward declare the function unlock_spatial_products_&lt;ALKIndex&gt; in the file from which the unlock function is to be called.</li><li> Ensure that the unlock_spatial_products_&lt;ALKIndex&gt;() function is called in the end-user application before accessing any Spatial functionality. The value for &lt;ALKIndex&gt; is the Application Key Index value returned on the Spatial Licensing Web site's final screen upon generating a license key. <b>Note for ACIS products: </b>The call to unlock_spatial_products_&lt;ALKIndex&gt;() must be made after ensuring that the Base component is initialized. The necessary sequence of events is to call unlock_spatial_products_&lt;ALKIndex&gt;() after the call to   initialize_base(). The reason for this requirement is that licensing is a consumer of the memory management system which is initialized simultaneously with the Base component. Calling initialization APIs associated with other libraries such as Deformable Modeling or Warping before calling the unlock function is possible to do, however unlock_spatial_products_&lt;ALKIndex&gt;() must be called before attempting to use any modeling functionality.</li><li> Note that the call to   spa_unlock_products(). The return values and what they indicate are as follows:<ul><li> SPA_UNLOCK_PASS indicates that the licensed products have been successfully unlocked.</li><li> SPA_UNLOCK_PASS_WARN indicates that the licensed products have been successfully unlocked, but the validation manager has issued a warning. Warnings typically occur when the license is set to expire in some time period.</li><li> SPA_UNLOCK_FAIL indicates that an error occurred during validation of the application key or during registration, in which case all Spatial products remain locked.</li></ul></li><li> The following libraries are needed by your application at runtime. Through the use of #pragma comment directives, these libraries are linked into your application automatically by building the function unlock_spatial_products_&lt;ALKIndex&gt;:</li></ol><dl><dd><dl><dd><ul><li> SPALicExtBase.dll</li><li> SPALicErrGUI.dll</li></ul></dd></dl>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -