Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

VisitingFunctions.h

Go to the documentation of this file.
00001 
00002 //                            VisitingFunctions.h                             //
00004 
00005 #ifndef VISITINGFUNCTIONS_H
00006 #define VISITINGFUNCTIONS_H
00007 
00008 #include "EnterFunction.h"
00009 #include "WalkOnFunction.h"
00010 #include "LeaveFunction.h"
00011 
00012 namespace X3DTK {
00013 
00016 
00017 class VisitingFunctions
00018 {
00019 public:
00021   VisitingFunctions(const EnterFunction *enter, const WalkOnFunction *walkon, const LeaveFunction *leave);
00023   ~VisitingFunctions();
00024   
00026   void setEnterFunction(const EnterFunction *enter);
00028   void setWalkOnFunction(const WalkOnFunction *walkon);
00030   void setLeaveFunction(const LeaveFunction *leave);
00031 
00033   inline void enter(SFAbstractNode N) const {enter_->enter(N);};
00035   inline bool walkOn(SFAbstractNode N, SFAbstractNode child = 0) const {return walkon_->walkOn(N, child);};  
00037   inline void leave(SFAbstractNode N) const  {leave_->leave(N);};
00038 
00039 private:
00040   EnterFunction *enter_;
00041   WalkOnFunction *walkon_;
00042   LeaveFunction *leave_;
00043 };
00044 
00045 }
00046 
00047 #endif

Generated on Thu Oct 9 13:50:55 2003 for X3DToolKit by doxygen1.2.18