Shiokaze Framework
A research-oriented fluid solver for computer graphics
dylibloader Class Reference

Class that takes in charge of loading dynamic libraries. More...

#include <dylibloader.h>

Inheritance diagram for dylibloader:
configurable

Public Member Functions

 dylibloader ()
 Default constructor for dylibloader.
 
virtual ~dylibloader ()
 Default destructor for dylibloader. close_library() will be also called if necessary.
 
bool open_library (std::string path)
 Load dynamic libraries. More...
 
void close_library ()
 Unload dynamic library.
 
const void * get_handle () const
 Get the native pointer to the loaded dynamic library. More...
 
void * load_symbol (std::string name) const
 Load function of global variable. More...
 
void load (configuration &config) override
 Call the function symbol "load". More...
 
void configure (configuration &config) override
 Call the function symbol "configure". More...
 
void overwrite (configuration &config) const
 Call the function symbol "overwrite", expecting that some configuration will be overwritten. More...
 
- Public Member Functions inherited from configurable
virtual void initialize (const environment_map &environment)
 Initialize the program. Used to get things ready for actual use. More...
 
virtual void setup_now (configuration &config=get_global_configuration())
 Run load - configure - initialize processes.
 
virtual bool not_recursive ()
 Check if this instance is not derived from recursive_configurable. More...
 

Additional Inherited Members

- Public Types inherited from configurable
using environment_map = std::map< std::string, const void * >
 Type for environment_map.
 
- Static Public Member Functions inherited from configurable
static configurationset_global_configuration (const configuration &config)
 Assign the global settings of the program. More...
 
static configurationget_global_configuration ()
 Get the global settings of the program. More...
 
template<class T >
static const T & get_env (const environment_map &environment, std::string key)
 Extract an specified type of pointer from the input environment. More...
 
- Protected Member Functions inherited from configurable
bool check_set (const environment_map &environment, std::vector< std::string > names)
 Check if the values for a variable keys exist. More...
 

Detailed Description

Class that takes in charge of loading dynamic libraries.

Member Function Documentation

◆ configure()

void dylibloader::configure ( configuration config)
overridevirtual

Call the function symbol "configure".

Parameters
[in]configConfiguration setting.

Reimplemented from configurable.

◆ get_handle()

const void* dylibloader::get_handle ( ) const
inline

Get the native pointer to the loaded dynamic library.

Returns
Pointer to the loaded library.

◆ load()

void dylibloader::load ( configuration config)
overridevirtual

Call the function symbol "load".

Parameters
[in]configConfiguration setting.

Reimplemented from configurable.

◆ load_symbol()

void* dylibloader::load_symbol ( std::string  name) const

Load function of global variable.

Returns
Pointer to the loaded function or global variable.

◆ open_library()

bool dylibloader::open_library ( std::string  path)

Load dynamic libraries.

Parameters
[in]pathPath to the dynamic library.

◆ overwrite()

void dylibloader::overwrite ( configuration config) const

Call the function symbol "overwrite", expecting that some configuration will be overwritten.

Parameters
[in]configConfiguration setting.

The documentation for this class was generated from the following file: