#include <maciLibraryManager.h>
Collaboration diagram for maci::LibraryManager:
Public Types | |
typedef bool(* | DLLOpenFunc )(int argc, char *argv[]) |
typedef void(* | DLLCloseFunc )(void) |
typedef void(* | DLLSetupCORBAFunc )(CORBA::ORB_ptr m_orb, PortableServer::POAManager_ptr m_poaManager, PortableServer::POA_ptr m_poaRoot, PortableServer::POA_ptr m_poaPersistent, PortableServer::POA_ptr m_poaTransient) |
typedef void(* | DLLInitThreadsFunc )(InitThreadFunc initFunc, DoneThreadFunc doneFunc) |
Public Member Functions | |
LibraryManager () | |
~LibraryManager () | |
void | setSearchPath (const char *path) |
const char * | getSearchPath () |
void | closeAllLibraries (bool inform=true) |
char * | locateLibrary (const char *name) |
void | lock (int h) |
void | unlock (int h) |
int | load (const char *path, int argc=0, char *argv[]=0) |
void | unload (int h) |
void | unload (const char *name) |
void * | getSymbol (int h, const char *symbol) |
bool | setupCORBAinDLL (int handle, CORBA::ORB_ptr m_orb, PortableServer::POAManager_ptr m_poaManager, PortableServer::POA_ptr m_poaRoot, PortableServer::POA_ptr m_poaPersistent, PortableServer::POA_ptr m_poaTransient) |
bool | initThreadsInDLL (int handle, InitThreadFunc initFunc, DoneThreadFunc doneFunc) |
Private Member Functions | |
int | ldfind (const ACE_TCHAR filename[], ACE_TCHAR pathname[], size_t maxpathnamelen) |
Logging::Logger::LoggerSmartPtr | getLogger () |
Private Attributes | |
Registrar< int, LibraryInfo > | m_libraries |
Data about all loadrd libraries. | |
char * | m_path |
Search path. | |
ACE_Recursive_Thread_Mutex | mutex |
Thread synchornization mutex. | |
Logging::Logger::LoggerSmartPtr | logger_m |
Logger for this container;. |
|
Declaration of the DLLClose function. A DLL that expects to be unloaded by the DLL Manager can export a function named "DLLClose". The DLL Manager then invokes this function just before it unloads the DLL. |
|
Declaration of the DLLInitThreads function. A DLL that expects to be loaded by the DLL Manager can export a function named "DLLInitThreads". The DLL Manager then invokes this function just after it loads the DLL.
|
|
Declaration of the DLLOpen function. A DLL that expects to be loaded by the DLL Manager can export a function named "DLLOpen". The DLL Manager then invokes this function just after it loads the DLL.
|
|
Declaration of the DLLSetupCORBA function. A DLL that expects to be loaded by the DLL Manager can export a function named "DLLSetupCORBA". The DLL Manager then invokes this function just after it loads the DLL.
|
|
Constructor |
|
Destructor |
|
Close all currently opened libraries
|
|
Returns an ACS Logger created for this container.
|
|
Get path where to libraries can be found
|
|
Resolves symbol from the library
|
|
Calls "DLLInitThreads" in library with specified handle
|
|
Search throuh search path(s) for library with given name
|
|
Loads library
|
|
Get path of given library (e.g. ps returns /usr/lib/libps.so)
|
|
Lock library (increase reference counter)
|
|
Set path where to libraries can be found
|
|
Calls "DLLSetupCORBA" in library with specified handle
|
|
Forces to unload the library (ignoring existing references to this library) |
|
Forces to unload the library (ignoring existing references to this library) |
|
Unlock library (decrease reference counter)
|
|
Logger for this container;.
|
|
Data about all loadrd libraries.
|
|
Search path.
|
|
Thread synchornization mutex.
|