wns::Creator< T, KIND > Class Template Reference
Factory method interface to use as creator for
StaticFactory.
More...
#include <StaticFactory.hpp>
List of all members.
|
Public Member Functions |
| virtual KIND * | create () |
Detailed Description
template<typename T, typename KIND = T>
class wns::Creator< T, KIND >
Create instances of a given class. This is the default
Creator, creating instances using the new-operator and the default constructor.
Alternative implementations are possible to support different constructor signatures.
Note that there is one StaticFactory for each Creator template instantiation and thus for each constructor signature. That is, every implementation of an abstract interface has to implement the same constructor interface.
- Note:
- This creator does *not* support instantiation of interfaces. It is only capable of handling abstract interfaces. To implement a creator that can handle non-abstract interfaces, the create method of the Creator<KIND, KIND> specialization has be the same as the default template create method. Such a creator will not work for abstract interface classes (Referencing the new operator of an abstract class yields a compile time error.)
Definition at line 255 of file StaticFactory.hpp.
Member Function Documentation
template<typename T, typename KIND = T>
| virtual KIND* wns::Creator< T, KIND >::create |
( |
|
) |
[inline, virtual] |
The documentation for this class was generated from the following file: