2 #ifndef _BINARY_PLUGIN_HANDLE_H 3 #define _BINARY_PLUGIN_HANDLE_H 15 #include <plugin_handle.h> 16 #include <plugin_manager.h> 28 handle = dlopen(path, RTLD_LAZY);
31 Logger::getLogger()->error(
"Unable to load storage plugin %s, %s",
35 Logger::getLogger()->debug(
"%s - storage plugin / RTLD_LAZY - name :%s: path :%s:", __FUNCTION__, name, path);
41 handle = dlopen(path, RTLD_LAZY|RTLD_GLOBAL);
44 Logger::getLogger()->error(
"Unable to load plugin %s, %s",
48 Logger::getLogger()->debug(
"%s - other plugin / RTLD_LAZY|RTLD_GLOBAL - name :%s: path :%s:", __FUNCTION__, name, path);
52 void *GetInfo() {
return dlsym(handle,
"plugin_info"); }
53 void *ResolveSymbol(
const char* sym) {
return dlsym(handle, sym); }
54 void *getHandle() {
return handle; }
The PluginHandle class is used to represent an opaque handle to a plugin instance.
Definition: plugin_handle.h:24
The BinaryPluginHandle class is used to represent an interface to a plugin that is available in a bin...
Definition: binary_plugin_handle.h:22