API Guides > ConceptRT 3.x
ConceptFactory< T > Class Template Reference

Concept factory. More...

Detailed Description

template<class T>
class ConceptRT::ConceptFactory< T >

Concept factory.

Template Parameters
TType of element (must be a ConceptElement).
+ Inheritance diagram for ConceptFactory< T >:

Public Member Methods

 ConceptFactory (PCChar8 id)
 Constructor. More...
 
String GetId () const
 Gets the ConceptFactory identifier. More...
 
bool HasId (PCChar8 id) const
 Query if the factory has the same id than the given id. More...
 
- Public Member Methods inherited from BaseConceptFactory
virtual ConceptElementCreateObject () const
 Manages the object creation. More...
 

Protected Member Functions

ConceptElementInternalCreateObject () const
 Effectively allocates the object. More...
 

Constructor & Destructor Documentation

ConceptFactory ( PCChar8  id)
inline

Constructor.

Parameters
idThe identifier.

Methods Documentation

String GetId ( ) const
inlinevirtual

Gets the ConceptFactory identifier.

Returns
The ConceptFactory identifier.

Implements BaseConceptFactory.

bool HasId ( PCChar8  id) const
inlinevirtual

Query if the factory has the same id than the given id.

Parameters
idThe given id.
Returns
true if it maches, false if not.

Reimplemented from BaseConceptFactory.

ConceptElement* InternalCreateObject ( ) const
inlineprotectedvirtual

Effectively allocates the object.

Returns
null if it fails, else the new object.
Warning
Non-Deterministic: Will create object on the heap. Determinism when using ConceptRT library can be ensure by using Context Time Critical mechanisms.

Implements BaseConceptFactory.