PandA-2024.02
Data Structures
Factory.hpp File Reference

Generic factory class implementation with self-registering derived classes. More...

#include "custom_map.hpp"
#include "refcount.hpp"
#include "string_manipulation.hpp"
Include dependency graph for Factory.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

class  Factory< Base, Args >
 
struct  Factory< Base, Args >::Registrar< T >
 
class  Factory< Base, Args >::Key
 

Detailed Description

Generic factory class implementation with self-registering derived classes.

Base class of the factory should inherit from Factory and specify common instanciation arguments, while derived classes should inherit from Base::Registrar to be automatically registered in the factory internal registry. Finally, derived classes can be instantiated through the Create method.

Author
Michele Fiorito miche.nosp@m.le.f.nosp@m.iorit.nosp@m.o@po.nosp@m.limi..nosp@m.it $Revision$ $Date$ Last modified by $Author$

Definition in file Factory.hpp.


Generated on Mon Feb 12 2024 13:03:35 for PandA-2024.02 by doxygen 1.8.13