Cantera  3.1.0a1
Loading...
Searching...
No Matches
ExtensionManagerFactory Class Reference

A factory class for creating ExtensionManager objects. More...

#include <ExtensionManagerFactory.h>

Inheritance diagram for ExtensionManagerFactory:
[legend]

Detailed Description

A factory class for creating ExtensionManager objects.

Since
New in Cantera 3.0

Definition at line 18 of file ExtensionManagerFactory.h.

Public Member Functions

void deleteFactory () override
 Delete the static instance of this factory.
 
- Public Member Functions inherited from Factory< ExtensionManager >
ExtensionManagercreate (const string &name, Args... args)
 Create an object using the object construction function corresponding to "name" and the provided constructor arguments.
 
void reg (const string &name, function< ExtensionManager *(Args...)> f)
 Register a new object construction function.
 
void addAlias (const string &original, const string &alias)
 Add an alias for an existing registered type.
 
string canonicalize (const string &name)
 Get the canonical name registered for a type.
 
bool exists (const string &name) const
 Returns true if name is registered with this factory.
 
- Public Member Functions inherited from FactoryBase
virtual ~FactoryBase ()
 destructor
 

Static Public Member Functions

static shared_ptr< ExtensionManagerbuild (const string &extensionType)
 Create a new ExtensionManager.
 
static ExtensionManagerFactoryfactory ()
 Static function that returns the static instance of the factory, creating it if necessary.
 
- 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
 

Private Member Functions

 ExtensionManagerFactory ()=default
 Private constructor prevents direct usage.
 

Static Private Attributes

static ExtensionManagerFactorys_factory = 0
 static member of the single factory instance
 
static std::mutex s_mutex
 Decl for locking mutex for thermo factory singleton.
 

Additional Inherited Members

- Protected Member Functions inherited from Factory< ExtensionManager >
void addDeprecatedAlias (const string &original, const string &alias)
 Add a deprecated alias for an existing registered type.
 
- Protected Member Functions inherited from FactoryBase
 FactoryBase ()
 Constructor.
 
virtual void deleteFactory ()=0
 Virtual abstract function that deletes the factory.
 

Constructor & Destructor Documentation

◆ ExtensionManagerFactory()

ExtensionManagerFactory ( )
privatedefault

Private constructor prevents direct usage.

Member Function Documentation

◆ build()

static shared_ptr< ExtensionManager > build ( const string &  extensionType)
inlinestatic

Create a new ExtensionManager.

Definition at line 22 of file ExtensionManagerFactory.h.

◆ deleteFactory()

void deleteFactory ( )
overridevirtual

Delete the static instance of this factory.

Implements FactoryBase.

Definition at line 25 of file ExtensionManagerFactory.cpp.

◆ factory()

ExtensionManagerFactory & factory ( )
static

Static function that returns the static instance of the factory, creating it if necessary.

Definition at line 16 of file ExtensionManagerFactory.cpp.

Member Data Documentation

◆ s_factory

ExtensionManagerFactory * s_factory = 0
staticprivate

static member of the single factory instance

Definition at line 35 of file ExtensionManagerFactory.h.

◆ s_mutex

mutex s_mutex
staticprivate

Decl for locking mutex for thermo factory singleton.

Definition at line 41 of file ExtensionManagerFactory.h.


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