#include <Module.hpp>
PluginModule represents a loaded shared library in the filesystem.
◆ PluginModule() [1/2]
Pothos::PluginModule::PluginModule |
( |
void |
| ) |
|
◆ PluginModule() [2/2]
Pothos::PluginModule::PluginModule |
( |
const std::string & |
path | ) |
|
Create a PluginModule from a file path.
- Exceptions
-
PluginPluginModuleError | if the path does not exist |
PluginPluginModuleError | if the load fails |
- Parameters
-
path | the path to a loadable module on the file system |
◆ ~PluginModule()
Pothos::PluginModule::~PluginModule |
( |
void |
| ) |
|
◆ getFilePath()
std::string Pothos::PluginModule::getFilePath |
( |
void |
| ) |
const |
Get a file path for this module.
- Returns
- the file path for the shared library
◆ getPluginPaths()
const std::vector<std::string>& Pothos::PluginModule::getPluginPaths |
( |
void |
| ) |
const |
Get the paths that this module loaded into the plugin registry. Each path is a string that represents a path in the registry.
◆ getVersion()
std::string Pothos::PluginModule::getVersion |
( |
void |
| ) |
const |
Get a version string for the specified module. Modules may optionally provide version strings.
- Returns
- a version string or empty if no version provided
◆ null()
static const PluginModule& Pothos::PluginModule::null |
( |
void |
| ) |
|
|
static |
A reference to a permanent empty module.
◆ operator bool()
Pothos::PluginModule::operator bool |
( |
void |
| ) |
const |
|
explicit |
Does the module hold a loaded library?
- Returns
- true if the module is non-empty
◆ safeLoad()
static PluginModule Pothos::PluginModule::safeLoad |
( |
const std::string & |
path | ) |
|
|
static |
Test load this libray module within a separate process to avoid loading something destructive within this process. If the test load succeeds, the module will be loaded locally.
- Exceptions
-
PluginPluginModuleError | if the load fails |
- Parameters
-
path | the path to a loadable module on the file system |
- Returns
- the PluginModule loaded at the given file path
The documentation for this class was generated from the following file: