    

 ## On this page

  

 

 # sos\_capi\_common.h File Reference

 Last update: 10.02.2025 

C-API for utility functions (load/unload library, license management, error handling) [More...](#details)

[Go to the source code of this file.](sos__capi__common_8h_source.xhtml)

## <a name="enum-members"></a>Enumerations

Public type definitions

Pubic type definitions used within this API



enum [fmop\_error\_t](group__types.xhtml#ga4847f3fa2943ffd694eb6cbe169a8bec) {   
 [fmop\_success](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8beca41a0a2e83b0ac20d414f4b015522ce55) = 0, [fmop\_invalid\_handle](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becacef5c059b0dd649f97d5404db95c3ccf) = 1, [fmop\_exception\_occurred](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becadac3d9086cdab852d265dc924070c198) = 2, [fmop\_settings\_error](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8beca4040927e4d05d13e93b9f2c7373ca0cd) = 3,   
 [fmop\_model\_missing](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becaedda7a6dbd4f5dd3eedecca9ec7dc1e9) = 4, [fmop\_license\_error](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becacf8dfe2eaba2eada73a26e487a04f8fe) = 5, [fmop\_script\_error](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becab6e0160bb71d6930176d907409618f4d) = 6, [fmop\_script\_no\_object](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8beca749f1c6edf13b1303018d7a3632dc316) = 7,   
 [fmop\_script\_wrong\_type](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8beca32eddc7d860101cdbb8e1571c726ee91) = 8, [fmop\_not\_implemented](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8beca7fc167a096db0f31209791e0053de2ec) = 16382, [fmop\_const\_max](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8beca41b2d8995eb66857227a50e49e8f6016) = 16383   
 } Error code definitions. [More...](group__types.xhtml#ga4847f3fa2943ffd694eb6cbe169a8bec)  
 enum [fmop\_license\_t](group__types.xhtml#gafe21e382a604ef55cba4d683d706422e) { [fmop\_mesh\_signal](group__types.xhtml#gafe21e382a604ef55cba4d683d706422ea5b9372ca962a29cf37faac2948897143) = 10, [fmop\_mesh\_all](group__types.xhtml#gafe21e382a604ef55cba4d683d706422ea71a41e6fb1935010b6ed34037f7dae8c) = 30 } FMOP mesh features which need to be unlocked by a valid license. [More...](group__types.xhtml#gafe21e382a604ef55cba4d683d706422e)  
 enum [fmop\_dataobject\_types](group__types.xhtml#ga69eb42c1b3b49f22b9e73c6c9869cb75) { [fmop\_node\_data](group__types.xhtml#ga69eb42c1b3b49f22b9e73c6c9869cb75aaf0fb275c161febc56c4f10e62987049) = 0, [fmop\_element\_data](group__types.xhtml#ga69eb42c1b3b49f22b9e73c6c9869cb75a1ec31fe31f3b8a9fd9dd902b014499ef) = 1, [fmop\_scalar\_data](group__types.xhtml#ga69eb42c1b3b49f22b9e73c6c9869cb75a16a14aa0d55901638e165fb3a39b3870) = 3 } Data type definitions. [More...](group__types.xhtml#ga69eb42c1b3b49f22b9e73c6c9869cb75)  
 ## <a name="func-members"></a>Functions

License handling

API handling licenes requests



DYNARDO\_FMOP\_API [fmop\_error\_t](group__types.xhtml#ga4847f3fa2943ffd694eb6cbe169a8bec) [FMOP\_appendLicenseSearchPath](group__license__handling.xhtml#ga7086f4db3e639526b2b7fe9ce9392a24) (const char \*abs\_path) Appends another license search path to the default ones. [More...](group__license__handling.xhtml#ga7086f4db3e639526b2b7fe9ce9392a24)  
 DYNARDO\_FMOP\_API [fmop\_error\_t](group__types.xhtml#ga4847f3fa2943ffd694eb6cbe169a8bec) [FMOP\_acquireLicense](group__license__handling.xhtml#ga1cdd0d44e0ea8172b1f7f1095395da89) () Acquires an optiSLang enterprise license. [More...](group__license__handling.xhtml#ga1cdd0d44e0ea8172b1f7f1095395da89)  
 DYNARDO\_FMOP\_API bool [FMOP\_licenseLocked](group__license__handling.xhtml#ga462a99c932a9b5704aae42a15826e4c3) () Check whether any license feature was acquired. [More...](group__license__handling.xhtml#ga462a99c932a9b5704aae42a15826e4c3)  
 DYNARDO\_FMOP\_API [fmop\_error\_t](group__types.xhtml#ga4847f3fa2943ffd694eb6cbe169a8bec) [FMOP\_releaseLicense](group__license__handling.xhtml#ga62d038d686a8183e10f52131697bce6c) () Release the acquired license. [More...](group__license__handling.xhtml#ga62d038d686a8183e10f52131697bce6c)  
 Error Handling

API to access and interpret recent data object error messages



DYNARDO\_FMOP\_API const char \* [FMOP\_getLastErrorString](group__error__handling.xhtml#ga5e19e7fe152759a80115e908c593245d) () Returns internal log messages of level warning and above. [More...](group__error__handling.xhtml#ga5e19e7fe152759a80115e908c593245d)  
 DYNARDO\_FMOP\_API [fmop\_error\_t](group__types.xhtml#ga4847f3fa2943ffd694eb6cbe169a8bec) [FMOP\_getLastErrno](group__error__handling.xhtml#gac78d83f9f73afd90854e1d07657fc186) () Returns the error number which has been set at the last library call. [More...](group__error__handling.xhtml#gac78d83f9f73afd90854e1d07657fc186)  
 DYNARDO\_FMOP\_API const char \* [FMOP\_getLastErrnoString](group__error__handling.xhtml#gaa838a7c375fc1d01d51636ad52a182ad) () Returns a pointer to a string that describes the error code which has been set at the last library call. [More...](group__error__handling.xhtml#gaa838a7c375fc1d01d51636ad52a182ad)  
 DYNARDO\_FMOP\_API const char \* [FMOP\_getLastLogString](group__error__handling.xhtml#gad78d4b2f659d76cce9d16eb7b0e10e2c) () Returns internal log messages of log levels defined by FMOP\_setLogLevel. Serves as debug logger. [More...](group__error__handling.xhtml#gad78d4b2f659d76cce9d16eb7b0e10e2c)  
 DYNARDO\_FMOP\_API int [FMOP\_setLogLevel](group__error__handling.xhtml#gac13c87c4e4d30a83f4d041a908d0a1e7) (int log\_level) Defines the new log level filter. Valid for all subsequent library calls until a new log level gets set. [More...](group__error__handling.xhtml#gac13c87c4e4d30a83f4d041a908d0a1e7)  
 DYNARDO\_FMOP\_API const char \* [FMOP\_getErrnoString](group__error__handling.xhtml#ga7e820b85d2ef2596b00bc82445dcf650) ([fmop\_error\_t](group__types.xhtml#ga4847f3fa2943ffd694eb6cbe169a8bec) error\_num) Returns a string description for the error number given. [More...](group__error__handling.xhtml#ga7e820b85d2ef2596b00bc82445dcf650)  
 Miscellaneous

DYNARDO\_FMOP\_API const char \* [FMOP\_getVersionString](group__misc.xhtml#ga4f2de6ba4f98c98d1c670fa4a9117150) () Returns a version string. [More...](group__misc.xhtml#ga4f2de6ba4f98c98d1c670fa4a9117150)  
 FMOP library handling

DYNARDO\_FMOP\_API [fmop\_error\_t](group__types.xhtml#ga4847f3fa2943ffd694eb6cbe169a8bec) [FMOP\_initializeLibrary](group__libhandling.xhtml#ga9c8f0f808d3f27c57a3a57d5f9cf4834) () Initialize the FMOP library Allocates memory for the global script engine. Call [FMOP\_unloadLibrary()](group__libhandling.xhtml#gae0af273cc642061f90933b4af2a958ad "Unload the FMOP library Clears the FMOP library from memory. A warning is logged if the library was u...") to release it. A warning is logged if the library was initialized already. [More...](group__libhandling.xhtml#ga9c8f0f808d3f27c57a3a57d5f9cf4834)  
 DYNARDO\_FMOP\_API [fmop\_error\_t](group__types.xhtml#ga4847f3fa2943ffd694eb6cbe169a8bec) [FMOP\_unloadLibrary](group__libhandling.xhtml#gae0af273cc642061f90933b4af2a958ad) () Unload the FMOP library Clears the FMOP library from memory. A warning is logged if the library was unloaded already.   
 <a id="details" name="details"></a>## Detailed Description

C-API for utility functions (load/unload library, license management, error handling)

CopyrightDYNARDO Austria GmbH