32 #include <casacore/casa/aips.h>
105 const std::string& prefix=std::string(),
106 const std::string& funcName=std::string(),
107 bool closeOnDestruction=
True);
112 const std::string& prefix,
113 const std::string& version,
114 const std::string& funcName,
115 bool closeOnDestruction=
True);
122 Bool closeOnDestruction,
123 const std::string& prefix=
"lib",
125 const std::string& suffix=
".dylib");
127 const std::string& suffix=
".so");
165 const std::string& prefix,
166 const std::string& version,
167 const std::string& funcName);
173 const std::string& libdir,
174 const std::string& prefix,
175 const std::string& version);
178 void open (
const std::string& name);
185 const std::string& prefix,
186 const std::string& version);
void open(const std::string &name)
Open (load) the dynamic library.
DynLib(const std::string &library, const std::string &prefix, const std::string &version, const std::string &funcName, bool closeOnDestruction=True)
The same as above, but it is tried with and without the given version (in that order).
DynLib(const std::string &library, Bool closeOnDestruction, const std::string &prefix="lib", const std::string &suffix=".so")
Load the dynamic library with the given name, prefix, and suffix.
void * getFunc(const std::string &funcName)
Get a pointer to a function in the dynamic library.
void close()
Close (unload) the dynamic library (if opened).
const std::string & getError() const
Get the possible error.
std::string tryCasacorePath(const std::string &library, const std::string &prefix, const std::string &version)
Try if the library can be opened using CASACORE_LDPATH.
std::string tryOpen(const std::string &name, const std::string &libdir, const std::string &prefix, const std::string &version)
Try to open the library with some prefixes, suffixes and versions If successful, itsHandle is filled ...
void attach(const std::string &name, const std::string &prefix, const std::string &version, const std::string &funcName)
Try to open the library with some prefixes, suffixes and versions and to execute the initialization f...
DynLib(const std::string &library, const std::string &prefix=std::string(), const std::string &funcName=std::string(), bool closeOnDestruction=True)
Load the dynamic library.
~DynLib()
Close the dynamic library if told so in the constructor.
void * getHandle() const
Get the dynamic library handle.
this file contains all the compiler specific defines
bool Bool
Define the standard types used by Casacore.