X3D_Creator.h

Go to the documentation of this file.
00001 #ifndef X3DTK_CREATOR_H
00002 #define X3DTK_CREATOR_H
00003 
00004 #include "X3D_X3DNode.h"
00005 #include "CreationFunction.h"
00006 #include "X3DActor.h"
00007 
00008 namespace X3DTK {
00009 namespace X3D {
00010 
00011 class X3DComponentCreator;
00012 
00020 class Creator : public X3DActor
00021 {
00022 public:  
00024   Creator();
00026   virtual ~Creator();
00027   
00029   void setComponentCreator(X3DComponentCreator *component);
00031   X3D::X3DNode *createFromName(const SFString &name) const;
00033   void reset();
00034   
00036   SFString getComponentNameOf(const SFString &name) const;
00037 
00038   friend Creator *joinCreator(Creator *N0, Creator *N1);
00039   
00040 private:  
00042   CreationFunction *getCreationFunctionOf(const SFString &name) const;
00043   
00044   //Dictionary of all the creation functions used.
00045   CreationDict _creationDict;
00046   std::list<X3DComponentCreator *> _componentList;
00047 };
00048 
00049 }
00050 }
00051 
00052 #endif

Generated on Fri Aug 27 13:16:23 2004 for X3DToolKit by doxygen 1.3.6