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

Class for managing the workflow of load - configure - initialize. More...

#include <configurable.h>

Inheritance diagram for configurable:
dylibloader ordering_driver parallel_driver recursive_configurable recursive_configurable_driver< T > array2< T > array3< T > bitarray2 bitarray3 bitmacarray2 bitmacarray3 macarray2< T > macarray3< T > recursive_configurable_module

Public Types

using environment_map = std::map< std::string, const void * >
 Type for environment_map.
 

Public Member Functions

virtual void load (configuration &config)
 Load the program. Used to load files and libraries into memory. More...
 
virtual void configure (configuration &config)
 Configure the program. Used to load and set parameters. More...
 
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...
 

Static Public Member Functions

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

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 for managing the workflow of load - configure - initialize.

Member Function Documentation

◆ check_set()

bool configurable::check_set ( const environment_map environment,
std::vector< std::string >  names 
)
inlineprotected

Check if the values for a variable keys exist.

Returns
true if all the values for the keys exist. false otherwise.

◆ configure()

virtual void configurable::configure ( configuration config)
inlinevirtual

Configure the program. Used to load and set parameters.

Parameters
[in]configConfiguration setting.

Reimplemented in recursive_configurable_driver< T >, and dylibloader.

◆ get_env()

template<class T >
static const T& configurable::get_env ( const environment_map environment,
std::string  key 
)
inlinestatic

Extract an specified type of pointer from the input environment.

Returns
Extracted pointer.

◆ get_global_configuration()

static configuration& configurable::get_global_configuration ( )
static

Get the global settings of the program.

Returns
Configuration setting.

◆ initialize()

virtual void configurable::initialize ( const environment_map environment)
inlinevirtual

Initialize the program. Used to get things ready for actual use.

Parameters
[in]configConfiguration setting.

Reimplemented in runnable, and recursive_configurable_driver< T >.

◆ load()

virtual void configurable::load ( configuration config)
inlinevirtual

Load the program. Used to load files and libraries into memory.

Parameters
[in]configConfiguration setting.

Reimplemented in recursive_configurable_driver< T >, and dylibloader.

◆ not_recursive()

virtual bool configurable::not_recursive ( )
inlinevirtual

Check if this instance is not derived from recursive_configurable.

Returns
true if the class is not inherited from recursive_configurable. false if inherited.

Reimplemented in recursive_configurable.

◆ set_global_configuration()

static configuration& configurable::set_global_configuration ( const configuration config)
static

Assign the global settings of the program.

Parameters
[in]configConfiguration setting.

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