13 #ifndef USSHAREDLIBRARY_H
14 #define USSHAREDLIBRARY_H
24 class SharedLibraryPrivate;
#define MITKCPPMICROSERVICES_EXPORT
The SharedLibrary class loads shared libraries at runtime.
void Unload()
Un-loads the shared library pointed to by this SharedLibrary object.
std::string GetName() const
Gets the base name of the shared library.
void SetName(const std::string &name)
Sets the base name of the shared library. Does nothing if the shared library is already loaded or the...
void SetFilePath(const std::string &absoluteFilePath)
Sets the absolute file path of this SharedLibrary object. Using this methods with a non-empty absolut...
void Load()
Loads the shared library pointed to by this SharedLibrary object. On POSIX systems dlopen() is called...
bool IsLoaded() const
Gets the loaded/unloaded stated of this SharedLibrary object.
std::string GetPrefix() const
Gets the file name prefix of this SharedLibrary object.
SharedLibrary()
Default constructor.
SharedLibrary(const std::string &absoluteFilePath)
Construct a SharedLibrary object using an absolute file path to the shared library....
void SetSuffix(const std::string &suffix)
Sets the suffix for shared library names (e.g. .dll or .so). Does nothing if the shared library is al...
std::string GetFilePath(const std::string &name) const
Gets the absolute file path for the shared library with base name name, using the search path returne...
void SetLibraryPath(const std::string &path)
Sets a new library search path. Does nothing if the shared library is already loaded or the SharedLib...
~SharedLibrary()
Destroys this object but does not unload the shared library.
std::string GetSuffix() const
Gets the file name suffix of this SharedLibrary object.
void * GetHandle() const
Gets the internal handle of this SharedLibrary object.
void Load(int flags)
Loads the shared library pointed to by this SharedLibrary object, using the specified flags on POSIX ...
SharedLibrary(const std::string &libPath, const std::string &name)
Construct a SharedLibrary object using a library search path and a library base name.
std::string GetFilePath() const
Gets the absolute file path of this SharedLibrary object.
SharedLibrary(const SharedLibrary &other)
Copy constructor.
std::string GetLibraryPath() const
Gets the library search path of this SharedLibrary object.
SharedLibrary & operator=(const SharedLibrary &other)
Assignment operator.
void SetPrefix(const std::string &prefix)
Sets the file name prefix for shared library names (e.g. lib). Does nothing if the shared library is ...