struggling a little with API exposure between modules and C++ types, needs a complete overhaul for checksums -- snapshot commit -- not functional

This commit is contained in:
Chris Punches
2025-03-31 02:03:18 -04:00
parent 045294aeb6
commit 81645c6d09
11 changed files with 573 additions and 223 deletions

View File

@@ -33,6 +33,7 @@
#include <string>
#include <sys/stat.h>
#include <dlfcn.h>
#include "ModuleOperations.hpp"
/**
* @brief Fatal log level constant
@@ -163,59 +164,6 @@ extern "C" {
* @return The module path
*/
const char* dpm_get_module_path(void);
/**
* @brief Checks if a module exists
*
* Verifies if a module exists at the configured module path.
*
* @param module_name Name of the module to check
* @return true if the module exists, false otherwise
*/
bool dpm_module_exists(const char* module_name);
/**
* @brief Loads a DPM module
*
* Attempts to load a module from the configured module path.
*
* @param module_name Name of the module to load
* @param module_handle Pointer to store the loaded module handle
* @return 0 on success, non-zero on failure
*/
int dpm_load_module(const char* module_name, void** module_handle);
/**
* @brief Checks if a symbol exists in a module
*
* Verifies if a specific symbol exists in a loaded module.
*
* @param module_handle Handle to a loaded module
* @param symbol_name Name of the symbol to check
* @return true if the symbol exists, false otherwise
*/
bool dpm_symbol_exists(void* module_handle, const char* symbol_name);
/**
* @brief Executes a symbol in a module
*
* Attempts to execute a function in a loaded module.
*
* @param module_handle Handle to a loaded module
* @param symbol_name Name of the symbol to execute
* @param args Arguments to pass to the function
* @return 0 on success, non-zero on failure
*/
int dpm_execute_symbol(void* module_handle, const char* symbol_name, void* args);
/**
* @brief Unloads a module
*
* Frees resources used by a loaded module.
*
* @param module_handle Handle to a loaded module
*/
void dpm_unload_module(void* module_handle);
}
/**