Cantera
3.1.0a1
|
Factory class for thermodynamic property managers. More...
#include <ThermoFactory.h>
Factory class for thermodynamic property managers.
This class keeps a list of the known ThermoPhase classes, and is used to create new instances of these classes.
Definition at line 30 of file ThermoFactory.h.
Public Member Functions | |
void | deleteFactory () override |
delete the static instance of this factory More... | |
Public Member Functions inherited from Factory< ThermoPhase > | |
ThermoPhase * | create (const string &name, Args... args) |
Create an object using the object construction function corresponding to "name" and the provided constructor arguments. More... | |
void | reg (const string &name, function< ThermoPhase *(Args...)> f) |
Register a new object construction function. More... | |
void | addAlias (const string &original, const string &alias) |
Add an alias for an existing registered type. More... | |
string | canonicalize (const string &name) |
Get the canonical name registered for a type. More... | |
bool | exists (const string &name) const |
Returns true if name is registered with this factory. More... | |
Public Member Functions inherited from FactoryBase | |
virtual | ~FactoryBase () |
destructor More... | |
Static Public Member Functions | |
static ThermoFactory * | factory () |
Static function that creates a static instance of the factory. More... | |
Static Public Member Functions inherited from FactoryBase | |
static void | deleteFactories () |
static function that deletes all factories in the internal registry maintained in a static variable More... | |
Private Member Functions | |
ThermoFactory () | |
Private constructors prevents usage. More... | |
Static Private Attributes | |
static ThermoFactory * | s_factory = 0 |
static member of a single instance More... | |
static std::mutex | thermo_mutex |
Decl for locking mutex for thermo factory singleton. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from Factory< ThermoPhase > | |
void | addDeprecatedAlias (const string &original, const string &alias) |
Add a deprecated alias for an existing registered type. More... | |
Protected Member Functions inherited from FactoryBase | |
FactoryBase () | |
Constructor. More... | |
|
private |
Private constructors prevents usage.
Definition at line 49 of file ThermoFactory.cpp.
|
static |
Static function that creates a static instance of the factory.
Definition at line 103 of file ThermoFactory.cpp.
|
overridevirtual |
delete the static instance of this factory
Implements FactoryBase.
Definition at line 112 of file ThermoFactory.cpp.
|
staticprivate |
static member of a single instance
Definition at line 41 of file ThermoFactory.h.
|
staticprivate |
Decl for locking mutex for thermo factory singleton.
Definition at line 47 of file ThermoFactory.h.