X3DMemberFunctor.h

Go to the documentation of this file.
00001 #ifndef X3DMEMBERFUNCTOR_H
00002 #define X3DMEMBERFUNCTOR_H
00003 
00004 #include "X3DField.h"
00005 
00006 namespace X3DTK {
00007 
00008 class X3DAbstractNode;
00009 
00010 class X3DMemberFunctor
00011 {
00012 public:
00013   virtual X3DField getValueOf(X3DAbstractNode const *N) const = 0;
00014   virtual void setValueOf(X3DAbstractNode *N, const X3DField &field) = 0;
00015 };
00016 
00017 template<class T, class V>
00018 class MemberFunctor : public X3DMemberFunctor
00019 {
00020 public:
00021   MemberFunctor(V T:: *member);
00022   
00023   X3DField getValueOf(X3DAbstractNode const *N) const;
00024   void setValueOf(X3DAbstractNode *N, const X3DField &field);
00025  
00026 private:
00027   V T:: *_member;
00028 };
00029 
00030 }
00031 
00032 #include "X3DMemberFunctor.inl"
00033 
00034 #endif

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