sofa::helper::Factory< TKey, TObject, TArgument > Class Template Reference

#include <Factory.h>

Collaboration diagram for sofa::helper::Factory< TKey, TObject, TArgument >:

Collaboration graph
[legend]

Public Types

typedef TKey Key
typedef TObject Object
typedef TArgument Argument
typedef BaseCreator< Object,
Argument > 
Creator
typedef std::multimap< Key,
Creator * >::iterator 
iterator
typedef std::multimap< Key,
Creator * >::const_iterator 
const_iterator

Public Member Functions

bool registerCreator (Key key, Creator *creator, bool multi=false)
Object * createObject (Key key, Argument arg)
iterator begin ()
iterator end ()
const_iterator begin () const
const_iterator end () const

Static Public Member Functions

static Factory< Key, Object,
Argument > * 
getInstance ()
static Object * CreateObject (Key key, Argument arg)

Protected Attributes

std::multimap< Key, Creator * > registry

Detailed Description

template<typename TKey, class TObject, typename TArgument>
class sofa::helper::Factory< TKey, TObject, TArgument >

Definition at line 61 of file Factory.h.


Member Typedef Documentation

template<typename TKey , class TObject , typename TArgument >
typedef TArgument sofa::helper::Factory< TKey, TObject, TArgument >::Argument

Definition at line 66 of file Factory.h.

template<typename TKey , class TObject , typename TArgument >
typedef std::multimap<Key, Creator*>::const_iterator sofa::helper::Factory< TKey, TObject, TArgument >::const_iterator

Definition at line 96 of file Factory.h.

template<typename TKey , class TObject , typename TArgument >
typedef BaseCreator<Object, Argument> sofa::helper::Factory< TKey, TObject, TArgument >::Creator

Definition at line 67 of file Factory.h.

template<typename TKey , class TObject , typename TArgument >
typedef std::multimap<Key, Creator*>::iterator sofa::helper::Factory< TKey, TObject, TArgument >::iterator

Definition at line 93 of file Factory.h.

template<typename TKey , class TObject , typename TArgument >
typedef TKey sofa::helper::Factory< TKey, TObject, TArgument >::Key

Definition at line 64 of file Factory.h.

template<typename TKey , class TObject , typename TArgument >
typedef TObject sofa::helper::Factory< TKey, TObject, TArgument >::Object

Definition at line 65 of file Factory.h.


Member Function Documentation

template<typename TKey , class TObject , typename TArgument >
const_iterator sofa::helper::Factory< TKey, TObject, TArgument >::begin (  )  const [inline]

template<typename TKey , class TObject , typename TArgument >
iterator sofa::helper::Factory< TKey, TObject, TArgument >::begin (  )  [inline]

template<typename TKey , class TObject , typename TArgument >
static Object* sofa::helper::Factory< TKey, TObject, TArgument >::CreateObject ( Key  key,
Argument  arg 
) [inline, static]

template<typename TKey , class TObject , typename TArgument >
TObject * sofa::helper::Factory< TKey, TObject, TArgument >::createObject ( Key  key,
Argument  arg 
) [inline]

template<typename TKey , class TObject , typename TArgument >
const_iterator sofa::helper::Factory< TKey, TObject, TArgument >::end (  )  const [inline]

template<typename TKey , class TObject , typename TArgument >
iterator sofa::helper::Factory< TKey, TObject, TArgument >::end (  )  [inline]

template<typename TKey , class TObject , typename TArgument >
Factory< TKey, TObject, TArgument > * sofa::helper::Factory< TKey, TObject, TArgument >::getInstance (  )  [inline, static]

template<typename TKey , class TObject , typename TArgument >
bool sofa::helper::Factory< TKey, TObject, TArgument >::registerCreator ( Key  key,
Creator *  creator,
bool  multi = false 
) [inline]


Field Documentation

template<typename TKey , class TObject , typename TArgument >
std::multimap<Key, Creator*> sofa::helper::Factory< TKey, TObject, TArgument >::registry [protected]


The documentation for this class was generated from the following files:

Generated on Sun Nov 23 04:24:15 2008 for Sofa by  doxygen 1.5.7.1