Component Registry. More...
#include <stdint.h>
#include <cmw-cmx/common.h>
Functions | |
int | cmx_registry_discover (cmx_component_info **const components, int *const len) |
Create array with information about all CMX Components. | |
void | cmx_registry_format_filename (char *filename_buf, const int process_id, const char *const component_name) |
int | cmx_registry_parse_filename (const char *filename_buf, int *const process_id, char *const component_name) |
int | cmx_registry_cleanup () |
Clean up orphaned cmx components. |
Component Registry.
int cmx_registry_cleanup | ( | ) |
Clean up orphaned cmx components.
Iterate through the main-registry and delete all components where the process-id is not related to a currently running process.
int cmx_registry_discover | ( | cmx_component_info **const | components, | |
int *const | len | |||
) |
Create array with information about all CMX Components.
The caller is obligated to call free() on the 'components' pointer if returncode is E_CMX_SUCCESS.
components | may be NULL | |
len | number of cmx components on this machine |
void cmx_registry_format_filename | ( | char * | filename_buf, | |
const int | process_id, | |||
const char *const | component_name | |||
) |
filename_buf | char buffer of size PATH_MAX (at least: 5 + (int_max in _10) + CMX_NAME_SZ) | |
process_id | ||
component_name |