|
@@ -26,31 +26,33 @@ void iniACIS(){
|
|
|
* @birth: created by czm in 20230922
|
|
|
*/
|
|
|
bool initIop(){
|
|
|
- // IOP is called in its own scope.
|
|
|
- // This sample uses a guard class that initializes InterOp upon
|
|
|
- // construction and terminates InterOp upon destruction. All
|
|
|
- // translations are done within the boundaries of a single
|
|
|
- // initialization and shutdown. InterOp may only be initialized
|
|
|
- // and shutdown once per process. Please do not use the guard
|
|
|
- // classes multiple times per process.
|
|
|
- SPAIopAcisSystemInitGuard initGuard(SPATIAL_LICENSE);
|
|
|
- int result = initGuard.GetInitStatus();
|
|
|
+// // IOP is called in its own scope.
|
|
|
+// // This sample uses a guard class that initializes InterOp upon
|
|
|
+// // construction and terminates InterOp upon destruction. All
|
|
|
+// // translations are done within the boundaries of a single
|
|
|
+// // initialization and shutdown. InterOp may only be initialized
|
|
|
+// // and shutdown once per process. Please do not use the guard
|
|
|
+// // classes multiple times per process.
|
|
|
+// SPAIopAcisSystemInitGuard initGuard(SPATIAL_LICENSE);
|
|
|
+// int result = initGuard.GetInitStatus();
|
|
|
|
|
|
- if (SPA_UNLOCK_NO_MSG == result)
|
|
|
- {
|
|
|
- // Spatial products have been unlocked
|
|
|
- printf("SUCCESS: SPAIopAcisSystem::Initialize. \n");
|
|
|
- }
|
|
|
- else if (SPA_UNLOCK_KEY_WARN_EXPIRE == result)
|
|
|
- printf("SPAIopAcisSystem::Initialize returned SPA_UNLOCK_KEY_WARN_EXPIRE; your license key will expire soon!\n");
|
|
|
- else if (SPA_UNLOCK_REGISTRATION_WARN_EXPIRE == result)
|
|
|
- printf("SPAIopAcisSystem::Initialize returned SPA_UNLOCK_REGISTRATION_WARN_EXPIRE; your registration will expire soon.\n");
|
|
|
- else
|
|
|
- {
|
|
|
- printf("SPAIopAcisSystem::Initialize returned an unexpected value; Contact Spatial Customer Support or your Account Manager.\n");
|
|
|
- return false;
|
|
|
- }
|
|
|
- result = 1;
|
|
|
+// if (SPA_UNLOCK_NO_MSG == result)
|
|
|
+// {
|
|
|
+// // Spatial products have been unlocked
|
|
|
+// printf("SUCCESS: SPAIopAcisSystem::Initialize. \n");
|
|
|
+// }
|
|
|
+// else if (SPA_UNLOCK_KEY_WARN_EXPIRE == result)
|
|
|
+// printf("SPAIopAcisSystem::Initialize returned SPA_UNLOCK_KEY_WARN_EXPIRE; your license key will expire soon!\n");
|
|
|
+// else if (SPA_UNLOCK_REGISTRATION_WARN_EXPIRE == result)
|
|
|
+// printf("SPAIopAcisSystem::Initialize returned SPA_UNLOCK_REGISTRATION_WARN_EXPIRE; your registration will expire soon.\n");
|
|
|
+// else
|
|
|
+// {
|
|
|
+// printf("SPAIopAcisSystem::Initialize returned an unexpected value; Contact Spatial Customer Support or your Account Manager.\n");
|
|
|
+// return false;
|
|
|
+// }
|
|
|
+// result = 1;
|
|
|
+ SPAIopAcisSystem::Shutdown();
|
|
|
+ SPAIopAcisSystem::Initialize(SPATIAL_LICENSE);
|
|
|
return true;
|
|
|
}
|
|
|
|