    

 ## On this page

  

 

 # Data handling

 Last update: 10.02.2025 

## <a name="member-group"></a>Create / Initialize Data Objects

<a class="anchor" id="amgrp810a929971f3e01bdcbaf2c18f0ff0c3"></a> API handling data object life time

DYNARDO\_FMOP\_API [fmop\_error\_t](group__types.xhtml#ga4847f3fa2943ffd694eb6cbe169a8bec) [FMOP\_loadDbFile](group__data__handling.xhtml#gadf36057836bc12095f01665fa068ba4c) ([fmop\_db\_handle\_t](fmop__solver_8h.xhtml#a4f3b1f4672b1b913e04f95def14d3572) \*database, const char \*path) Initializes a fmop\_db\_handle\_t object from a previously saved Statistics on Structures (SoS) database. [More...](#gadf36057836bc12095f01665fa068ba4c)  
 DYNARDO\_FMOP\_API [fmop\_error\_t](group__types.xhtml#ga4847f3fa2943ffd694eb6cbe169a8bec) [FMOP\_loadDbFileWMesh](group__data__handling.xhtml#gab3f6b6b4a84878f3c774a12a2b4cf958) ([fmop\_db\_handle\_t](fmop__solver_8h.xhtml#a4f3b1f4672b1b913e04f95def14d3572) \*database, const char \*path) Initializes a fmop\_db\_handle\_t object from a previously saved Statistics on Structures (SoS) database This function also builds up all internal data structures needed to represent FEM meshes. Hence it may need more CPU time and RAM. [More...](#gab3f6b6b4a84878f3c774a12a2b4cf958)  
 DYNARDO\_FMOP\_API [fmop\_error\_t](group__types.xhtml#ga4847f3fa2943ffd694eb6cbe169a8bec) [FMOP\_getModel](group__data__handling.xhtml#gaae65fdf242dba6c37b9de818be7c9dcc) ([fmop\_db\_handle\_t](fmop__solver_8h.xhtml#a4f3b1f4672b1b913e04f95def14d3572) database, [fmop\_dataobject\_types](group__types.xhtml#ga69eb42c1b3b49f22b9e73c6c9869cb75) data\_type, const char \*const fmop\_ident, [fmop\_handle\_t](fmop__solver_8h.xhtml#aed65d1ae14f8c298a702ad5b828a70ef) \*fmop) Loads a fmop\_handle\_t data object from the database given. [More...](#gaae65fdf242dba6c37b9de818be7c9dcc)  
 DYNARDO\_FMOP\_API [fmop\_error\_t](group__types.xhtml#ga4847f3fa2943ffd694eb6cbe169a8bec) [FMOP\_releaseModel](group__data__handling.xhtml#ga3ad01c460ed6e409b79e258a523d0bf9) ([fmop\_handle\_t](fmop__solver_8h.xhtml#aed65d1ae14f8c298a702ad5b828a70ef) \*fmop) Releases a fmop\_handle\_t object and dedicated memory. [More...](#ga3ad01c460ed6e409b79e258a523d0bf9)  
 DYNARDO\_FMOP\_API [fmop\_error\_t](group__types.xhtml#ga4847f3fa2943ffd694eb6cbe169a8bec) [FMOP\_releaseDb](group__data__handling.xhtml#gaf36d28d4c5c718284a0f4236f2740e06) ([fmop\_db\_handle\_t](fmop__solver_8h.xhtml#a4f3b1f4672b1b913e04f95def14d3572) \*database) Releases a fmop\_db\_handle\_t object and dedicated memory. [More...](#gaf36d28d4c5c718284a0f4236f2740e06)  
 DYNARDO\_FMOP\_API [fmop\_error\_t](group__types.xhtml#ga4847f3fa2943ffd694eb6cbe169a8bec) [FMOP\_releaseIdents](group__data__handling.xhtml#ga37bdee678571cd855ac0bb10675b1d8c) (char \*\*\*const idents, const size\_t \*num\_idents) An auxiliary function to releases an array of char arrays and dedicated memory. [More...](#ga37bdee678571cd855ac0bb10675b1d8c)  
 <a id="details" name="details"></a>## Detailed Description

## Function Documentation

<a id="gaae65fdf242dba6c37b9de818be7c9dcc"></a>## [◆ ](#gaae65fdf242dba6c37b9de818be7c9dcc)FMOP\_getModel()

 DYNARDO\_FMOP\_API [fmop\_error\_t](group__types.xhtml#ga4847f3fa2943ffd694eb6cbe169a8bec) FMOP\_getModel  ( [fmop\_db\_handle\_t](fmop__solver_8h.xhtml#a4f3b1f4672b1b913e04f95def14d3572)  *database*,    [fmop\_dataobject\_types](group__types.xhtml#ga69eb42c1b3b49f22b9e73c6c9869cb75)  *data\_type*,    const char \*const  *fmop\_ident*,    [fmop\_handle\_t](fmop__solver_8h.xhtml#aed65d1ae14f8c298a702ad5b828a70ef) \*  *fmop*   ) 

Loads a fmop\_handle\_t data object from the database given.

Parameters \[in\]databaseThe already initialized database handle \[in\]data\_typeThe data type in question \[in\]fmop\_identThe FMOP ident to be loaded from the database given \[in,out\]fmopOn input *\*fmop* must point to NULL. Returns an initialized fmop handle to the requested *fmop\_ident* on output. Pointer ownership is up to the caller after return. Call FMOP\_releaseModel (fmop\_handle\_t \*) at the end of lifetime. Returns- [fmop\_invalid\_handle](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becacef5c059b0dd649f97d5404db95c3ccf "The function got an unexpected NULL pointer. ") if the database or fmop\_ident argument is a NULL pointer
- [fmop\_invalid\_handle](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becacef5c059b0dd649f97d5404db95c3ccf "The function got an unexpected NULL pointer. ") if the *fmop* argument does not hold a NULL pointer on input
- [fmop\_license\_error](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becacf8dfe2eaba2eada73a26e487a04f8fe "No valid license available. ") if a license error occurs, e.g. no license has been acquired so far or one tries to load a 3D mesh but acquired a SoS license for 1D meshes, e.g. signals, only
- [fmop\_model\_missing](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becaedda7a6dbd4f5dd3eedecca9ec7dc1e9 "The requested model identifier is not known. ") if the handle initialization fails
- [fmop\_success](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8beca41a0a2e83b0ac20d414f4b015522ce55 "Function execution returned successfully. ") elsewise

Call [FMOP\_getErrnoString()](group__error__handling.xhtml#ga7e820b85d2ef2596b00bc82445dcf650 "Returns a string description for the error number given. ") to get a human readable representation NoteAssumes that FMOP\_initialize() returned fmop\_model\_successReturnsA success indicator. Call FMOP\_getErrnoString to get a human readable representation 



<a id="gadf36057836bc12095f01665fa068ba4c"></a>## [◆ ](#gadf36057836bc12095f01665fa068ba4c)FMOP\_loadDbFile()

 DYNARDO\_FMOP\_API [fmop\_error\_t](group__types.xhtml#ga4847f3fa2943ffd694eb6cbe169a8bec) FMOP\_loadDbFile  ( [fmop\_db\_handle\_t](fmop__solver_8h.xhtml#a4f3b1f4672b1b913e04f95def14d3572) \*  *database*,    const char \*  *path*   ) 

Initializes a fmop\_db\_handle\_t object from a previously saved Statistics on Structures (SoS) database.

Parameters \[in,out\]databaseOn input *\*database* must point to NULL. Returns an initialized handle to the loaded database on ouptut. The database of the returned handle has been set to the content of the file path given. Pointer ownership is up to the caller after return. Call FMOP\_releaseDb (fmop\_db\_handle\_t \*) at the end of lifetime. \[in\]pathThe path to the SoS database file as a NULL terminated character array Returns- [fmop\_invalid\_handle](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becacef5c059b0dd649f97d5404db95c3ccf "The function got an unexpected NULL pointer. ") if the database argument does not hold a NULL pointer on input
- [fmop\_settings\_error](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8beca4040927e4d05d13e93b9f2c7373ca0cd "Input argument(s) is invalid or missing. ") if the path argument doesn't point to an existing file
- [fmop\_license\_error](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becacf8dfe2eaba2eada73a26e487a04f8fe "No valid license available. ") if a license error occurs, e.g. no license has been acquired so far or one tries to load a 3D mesh but acquired a SoS license for 1D meshes, e.g. signals, only
- [fmop\_exception\_occurred](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becadac3d9086cdab852d265dc924070c198 "An internal error occurred. Request log messages. ") if any other failure get invoked
- [fmop\_success](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8beca41a0a2e83b0ac20d414f4b015522ce55 "Function execution returned successfully. ") if the fmop\_db\_handle\_t has been initialized successfully

Call [FMOP\_getErrnoString()](group__error__handling.xhtml#ga7e820b85d2ef2596b00bc82445dcf650 "Returns a string description for the error number given. ") to get a human readable representation. 



<a id="gab3f6b6b4a84878f3c774a12a2b4cf958"></a>## [◆ ](#gab3f6b6b4a84878f3c774a12a2b4cf958)FMOP\_loadDbFileWMesh()

 DYNARDO\_FMOP\_API [fmop\_error\_t](group__types.xhtml#ga4847f3fa2943ffd694eb6cbe169a8bec) FMOP\_loadDbFileWMesh  ( [fmop\_db\_handle\_t](fmop__solver_8h.xhtml#a4f3b1f4672b1b913e04f95def14d3572) \*  *database*,    const char \*  *path*   ) 

Initializes a fmop\_db\_handle\_t object from a previously saved Statistics on Structures (SoS) database This function also builds up all internal data structures needed to represent FEM meshes. Hence it may need more CPU time and RAM.

Parameters \[in,out\]databaseOn input *\*database* must point to NULL. Returns an initialized handle to the loaded database on ouptut. The database of the returned handle has been set to the content of the file path given. Pointer ownership is up to the caller after return. Call FMOP\_releaseDb (fmop\_db\_handle\_t \*) at the end of lifetime. \[in\]pathThe path to the SoS database file as a NULL terminated character array Returns- [fmop\_invalid\_handle](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becacef5c059b0dd649f97d5404db95c3ccf "The function got an unexpected NULL pointer. ") if the database argument does not hold a NULL pointer on input
- [fmop\_settings\_error](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8beca4040927e4d05d13e93b9f2c7373ca0cd "Input argument(s) is invalid or missing. ") if the path argument doesn't point to an existing file
- [fmop\_license\_error](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becacf8dfe2eaba2eada73a26e487a04f8fe "No valid license available. ") if a license error occurs, e.g. no license has been acquired so far or one tries to load a 3D mesh but acquired a SoS license for 1D meshes, e.g. signals, only
- [fmop\_exception\_occurred](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becadac3d9086cdab852d265dc924070c198 "An internal error occurred. Request log messages. ") if any other failure get invoked
- [fmop\_success](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8beca41a0a2e83b0ac20d414f4b015522ce55 "Function execution returned successfully. ") if the fmop\_db\_handle\_t has been initialized successfully

Call [FMOP\_getErrnoString()](group__error__handling.xhtml#ga7e820b85d2ef2596b00bc82445dcf650 "Returns a string description for the error number given. ") to get a human readable representation. 



<a id="gaf36d28d4c5c718284a0f4236f2740e06"></a>## [◆ ](#gaf36d28d4c5c718284a0f4236f2740e06)FMOP\_releaseDb()

 DYNARDO\_FMOP\_API [fmop\_error\_t](group__types.xhtml#ga4847f3fa2943ffd694eb6cbe169a8bec) FMOP\_releaseDb  ( [fmop\_db\_handle\_t](fmop__solver_8h.xhtml#a4f3b1f4672b1b913e04f95def14d3572) \*  *database*) 

Releases a fmop\_db\_handle\_t object and dedicated memory.

Parameters \[in,out\]databaseThe fmop\_db\_handle\_t to be released. Set to NULLptr on return. Returns- [fmop\_license\_error](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becacf8dfe2eaba2eada73a26e487a04f8fe "No valid license available. ") if a license error occurs, e.g. no license has been acquired so far or one tries to release a 3D mesh but acquired a SoS license for 1D meshes, e.g. signals, only
- [fmop\_exception\_occurred](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becadac3d9086cdab852d265dc924070c198 "An internal error occurred. Request log messages. ") if any other failure get invoked
- [fmop\_success](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8beca41a0a2e83b0ac20d414f4b015522ce55 "Function execution returned successfully. ") elsewise

Call [FMOP\_getErrnoString()](group__error__handling.xhtml#ga7e820b85d2ef2596b00bc82445dcf650 "Returns a string description for the error number given. ") to get a human readable representation 



<a id="ga37bdee678571cd855ac0bb10675b1d8c"></a>## [◆ ](#ga37bdee678571cd855ac0bb10675b1d8c)FMOP\_releaseIdents()

 DYNARDO\_FMOP\_API [fmop\_error\_t](group__types.xhtml#ga4847f3fa2943ffd694eb6cbe169a8bec) FMOP\_releaseIdents  ( char \*\*\*const  *idents*,    const size\_t \*  *num\_idents*   ) 

An auxiliary function to releases an array of char arrays and dedicated memory.

Parameters \[in,out\]identsA pointer to an array of char arrays. Set to NULLptr on return. \[in\]num\_identsAn already initialized scalar data object. Contains the number of idents in the char\*\* array \[\] given Returns- [fmop\_invalid\_handle](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becacef5c059b0dd649f97d5404db95c3ccf "The function got an unexpected NULL pointer. ") if the array argument is a NULL pointer or if \*array points to NULL
- [fmop\_license\_error](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becacf8dfe2eaba2eada73a26e487a04f8fe "No valid license available. ") if a license error occurs, e.g. no license has been acquired so far
- [fmop\_settings\_error](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8beca4040927e4d05d13e93b9f2c7373ca0cd "Input argument(s) is invalid or missing. ") if the num\_idents argument is a NULL pointer
- [fmop\_exception\_occurred](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becadac3d9086cdab852d265dc924070c198 "An internal error occurred. Request log messages. ") if any other failure get invoked
- [fmop\_success](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8beca41a0a2e83b0ac20d414f4b015522ce55 "Function execution returned successfully. ") elsewise

Call [FMOP\_getErrnoString()](group__error__handling.xhtml#ga7e820b85d2ef2596b00bc82445dcf650 "Returns a string description for the error number given. ") to get a human readable representation 



<a id="ga3ad01c460ed6e409b79e258a523d0bf9"></a>## [◆ ](#ga3ad01c460ed6e409b79e258a523d0bf9)FMOP\_releaseModel()

 DYNARDO\_FMOP\_API [fmop\_error\_t](group__types.xhtml#ga4847f3fa2943ffd694eb6cbe169a8bec) FMOP\_releaseModel  ( [fmop\_handle\_t](fmop__solver_8h.xhtml#aed65d1ae14f8c298a702ad5b828a70ef) \*  *fmop*) 

Releases a fmop\_handle\_t object and dedicated memory.

Parameters \[in,out\]fmopThe fmop\_handle\_t to be released. Set to NULLptr on return. Returns- [fmop\_license\_error](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becacf8dfe2eaba2eada73a26e487a04f8fe "No valid license available. ") if a license error occurs, e.g. no license has been acquired so far or one tries to release a 3D mesh but acquired a SoS license for 1D meshes, e.g. signals, only
- [fmop\_exception\_occurred](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8becadac3d9086cdab852d265dc924070c198 "An internal error occurred. Request log messages. ") if any other failure get invoked
- [fmop\_success](group__types.xhtml#gga4847f3fa2943ffd694eb6cbe169a8beca41a0a2e83b0ac20d414f4b015522ce55 "Function execution returned successfully. ") elsewise

Call [FMOP\_getErrnoString()](group__error__handling.xhtml#ga7e820b85d2ef2596b00bc82445dcf650 "Returns a string description for the error number given. ") to get a human readable representation