Cantera 2.6.0

Public Member Functions | Static Public Member Functions | Protected Member Functions | Static Private Attributes | List of all members
FactoryBase Class Referenceabstract

Base class for factories. More...

`#include <FactoryBase.h>`

Inheritance diagram for FactoryBase:
[legend]

## Public Member Functions
virtual | ~FactoryBase ()
| destructor More...

## Static Public Member Functions
static void | deleteFactories ()
| static function that deletes all factories in the internal registry maintained in a static variable More...

## Protected Member Functions
| FactoryBase ()
| Constructor. More...
virtual void | deleteFactory ()=0
| Virtual abstract function that deletes the factory. More...

## Static Private Attributes
static std::vector< FactoryBase * > | s_vFactoryRegistry
| statically held list of Factories. More...

## Detailed Description

Base class for factories.

This class maintains a registry of all factories that derive from it, and deletes them all when its static method deleteFactories is invoked.

Definition at line 26 of file FactoryBase.h.

## Constructor & Destructor Documentation

## ◆ ~FactoryBase()

virtual ~FactoryBase | ( |  | ) |
| inline virtual

destructor

Definition at line 31 of file FactoryBase.h.

## ◆ FactoryBase()

FactoryBase | ( |  | ) |
| inline protected

Constructor.

Adds the current object to the current static list

Definition at line 49 of file FactoryBase.h.

References FactoryBase::s_vFactoryRegistry.

## Member Function Documentation

## ◆ deleteFactories()

static void deleteFactories | ( |  | ) |
| inline static

static function that deletes all factories in the internal registry maintained in a static variable

Definition at line 36 of file FactoryBase.h.

References FactoryBase::s_vFactoryRegistry.

Referenced by Cantera::appdelete().

## ◆ deleteFactory()

virtual void deleteFactory | ( |  | ) |
| protected pure virtual

Virtual abstract function that deletes the factory.

This must be properly defined in child objects.

Implemented in FalloffFactory, KineticsFactory, ReactionRateFactory, ThermoFactory, TransportFactory, FlowDeviceFactory, ReactorFactory, WallFactory, and ReactionFactory.

## Member Data Documentation

## ◆ s_vFactoryRegistry

std::vector< FactoryBase * > s_vFactoryRegistry
| static private

statically held list of Factories.

Definition at line 61 of file FactoryBase.h.

Referenced by FactoryBase::deleteFactories(), and FactoryBase::FactoryBase().

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

- FactoryBase.h
- global.cpp