Abstract interface for creating objects of a particular type. More...
#include <rutz/factory.h>
Public Types | |
typedef T | base_t |
Public Member Functions | |
virtual | ~creator_base () |
Virtual destructor. | |
virtual creator_base * | clone () const =0 |
Return a clone of this Creator. | |
virtual base_t | create ()=0 |
Return a new pointer (or smart pointer) to type Base . |
Abstract interface for creating objects of a particular type.
rutz::creator_base is a template class that defines a single abstract function, create(), that returns an object of type creator_base::base_t.
Definition at line 57 of file factory.h.
virtual rutz::creator_base< T >::~creator_base | ( | ) | [inline, virtual] |
virtual creator_base* rutz::creator_base< T >::clone | ( | ) | const [pure virtual] |
Return a clone of this Creator.
Implemented in rutz::creator_from_func< base_t, derived_t >.
Referenced by rutz::factory< nub::ref< P > >::register_alias().
virtual base_t rutz::creator_base< T >::create | ( | ) | [pure virtual] |
Return a new pointer (or smart pointer) to type Base
.
Implemented in rutz::creator_from_func< base_t, derived_t >.
Referenced by rutz::factory< nub::ref< P > >::new_checked_object(), and rutz::factory< nub::ref< P > >::new_object().