00001 // rdCallbackSet.h 00002 //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 00003 // Copyright 2003 Realistic Dynamics, Inc. 00004 // All rights reserved. 00005 // 00006 // Please do not read, copy, distribute, or use without permission. 00007 // Contact: Frank C. Anderson, fca@RealisticDynamics.com 00008 //+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 00009 #ifndef __rdCallbackSet_h__ 00010 #define __rdCallbackSet_h__ 00011 00012 00013 // INCLUDES 00014 #include <rdPtrArray.h> 00015 #include "rdModel.h" 00016 #include "rdIntegCallback.h" 00017 00018 00019 //============================================================================= 00020 //============================================================================= 00027 class RDSIMULATION_API rdCallbackSet : public rdPtrArray 00028 { 00029 00030 //============================================================================= 00031 // DATA 00032 //============================================================================= 00033 public: 00034 static const int NUM_TYPES; 00035 protected: 00037 rdModel *_model; 00038 00039 //============================================================================= 00040 // METHODS 00041 //============================================================================= 00042 //-------------------------------------------------------------------------- 00043 // CONSTRUCTION 00044 //-------------------------------------------------------------------------- 00045 public: 00046 rdCallbackSet(rdModel *aModel); 00047 virtual ~rdCallbackSet(); 00048 void deleteCallbacks(); 00049 private: 00050 void setNull(); 00051 public: 00052 00053 //-------------------------------------------------------------------------- 00054 // GET AND SET 00055 //-------------------------------------------------------------------------- 00056 rdModel* getModel(); 00057 rdCallback* getCallback(int aIndex) const; 00058 void setOn(bool aTrueFalse); 00059 00060 //-------------------------------------------------------------------------- 00061 // CALLBACKS 00062 //-------------------------------------------------------------------------- 00063 00070 //============================================================================= 00071 }; // END of class rdCallbackSet 00072 //============================================================================= 00073 //============================================================================= 00074 00075 00076 #endif // __rdCallbackSet_h__ 00077 00078
1.3