|
Teuchos - Trilinos Tools Package Version of the Day
|
Simple, universal "Abstract Factory" interface for the dynamic creation of objects. More...
#include <Teuchos_AbstractFactory.hpp>
Public Types | |
| typedef Teuchos::RCP< T > | obj_ptr_t |
| | |
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. | |
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 48 of file Teuchos_AbstractFactory.hpp.
| typedef Teuchos::RCP<T> Teuchos::AbstractFactory< T >::obj_ptr_t |
Reimplemented in Teuchos::AbstractFactoryStd< T_itfc, T_impl, T_PostMod, T_Allocator >.
Definition at line 53 of file Teuchos_AbstractFactory.hpp.
| virtual Teuchos::AbstractFactory< T >::~AbstractFactory | ( | ) | [inline, virtual] |
Definition at line 57 of file Teuchos_AbstractFactory.hpp.
| virtual obj_ptr_t Teuchos::AbstractFactory< T >::create | ( | ) | const [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 >.
1.7.4