Teuchos Package Browser (Single Doxygen Collection)
Version of the Day
|
Simple, universal "Abstract Factory" interface for the dynamic creation of objects. More...
#include <Teuchos_AbstractFactory.hpp>
Public Member Functions | |
virtual | ~AbstractFactory () |
virtual obj_ptr_t | create () const =0 |
Create an object of type T returned as a smart reference counting pointer object. More... | |
Simple, universal "Abstract Factory" interface for the dynamic creation of objects.
While RCP
provides for specialized deallocation policies it does not abstract, in any way, how an object is first allocated. The most general way to abstract how an object is allocated is to use an "Abstract Factory". This base class defines the most basic "Abstract Factory" interface and defines only one virtual function, create()
that returns a RCP
-wrapped object.
Definition at line 29 of file Teuchos_AbstractFactory.hpp.
|
inlinevirtual |
Definition at line 38 of file Teuchos_AbstractFactory.hpp.
|
pure virtual |
Create an object of type T returned as a smart reference counting pointer object.
Implemented in Teuchos::AbstractFactoryStd< T_itfc, T_impl, T_PostMod, T_Allocator >.