![]() |
OpenWalnut
1.5.0dev
|
Simple class holding an opened library. More...
Collaboration diagram for WSharedLib::data:Public Member Functions | |
| ~data () | |
| Destructor. More... | |
| data (const std::string &path) | |
| Constructor. More... | |
| func_ptr_type | findFunction (const std::string &name) |
| Searches the lib for the specified function symbol and returns it. More... | |
| void * | findVariable (const std::string &name, bool suppressThrow=false) |
| Searches the lib for the specified symbol and returns it. More... | |
| bool | existsFunction (const std::string &name) |
| Check for existence of a given function pointer symbol. More... | |
Public Attributes | |
| const std::string | m_path |
| Path of lib. More... | |
| void * | m_dl |
| Handle describing the loaded lib. More... | |
Simple class holding an opened library.
Definition at line 171 of file WSharedLib.cpp.
|
inline |
Destructor.
Closes the previously opened library handle.
Definition at line 186 of file WSharedLib.cpp.
References m_dl.
|
inlineexplicit |
Constructor.
Opens and loads the library.
| path | the lib to open |
Definition at line 198 of file WSharedLib.cpp.
|
inline |
Check for existence of a given function pointer symbol.
| name | the symbol |
Definition at line 260 of file WSharedLib.cpp.
References findVariable().
Referenced by WSharedLib::existsFunction().
Here is the call graph for this function:
Here is the caller graph for this function:
|
inline |
Searches the lib for the specified function symbol and returns it.
| name | the name of the function |
| WLibraryFetchFailed | thrown if the symbol could not be found. |
Definition at line 218 of file WSharedLib.cpp.
References findVariable().
Referenced by WSharedLib::findFunction().
Here is the call graph for this function:
Here is the caller graph for this function:
|
inline |
Searches the lib for the specified symbol and returns it.
| name | the name of the symbol to search. |
| suppressThrow | set to true to suppress the exception. NULL is returned if the symbol does not exists |
| WLibraryFetchFailed | thrown if the symbol could not be found. |
Definition at line 240 of file WSharedLib.cpp.
References m_dl.
Referenced by existsFunction(), findFunction(), and WSharedLib::findVariable().
Here is the caller graph for this function:| void* WSharedLib::data::m_dl |
Handle describing the loaded lib.
Definition at line 181 of file WSharedLib.cpp.
Referenced by data(), findVariable(), and ~data().
| const std::string WSharedLib::data::m_path |