00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014 #ifndef __SIM_ConRelTwoState_h__
00015 #define __SIM_ConRelTwoState_h__
00016
00017 #include "SIM_API.h"
00018 #include "SIM_OptionsUser.h"
00019 #include "SIM_ConRel.h"
00020
00021
00022
00023 class SIM_API SIM_ConRelTwoState : public SIM_ConRel,
00024 public SIM_OptionsUser
00025 {
00026 public:
00027 GETSET_DATA_FUNCS_F(SIM_NAME_MINSTATETIME, MinStateTime);
00028 GETSET_DATA_FUNCS_F(SIM_NAME_LASTTRANSITIONTIME, LastTransitionTime);
00029 GETSET_DATA_FUNCS_I(SIM_NAME_CURRENTSTATE, CurrentState);
00030
00031 GETSET_DATA_FUNCS_I(SIM_NAME_FORCECOMPARE1, ForceCompare1);
00032 GETSET_DATA_FUNCS_F(SIM_NAME_FORCEVALUE1, ForceValue1);
00033 GETSET_DATA_FUNCS_I(SIM_NAME_DISTANCECOMPARE1, DistanceCompare1);
00034 GETSET_DATA_FUNCS_F(SIM_NAME_DISTANCEVALUE1, DistanceValue1);
00035 GETSET_DATA_FUNCS_I(SIM_NAME_FORCECOMPARE0, ForceCompare0);
00036 GETSET_DATA_FUNCS_F(SIM_NAME_FORCEVALUE0, ForceValue0);
00037 GETSET_DATA_FUNCS_I(SIM_NAME_DISTANCECOMPARE0, DistanceCompare0);
00038 GETSET_DATA_FUNCS_F(SIM_NAME_DISTANCEVALUE0, DistanceValue0);
00039
00040 protected:
00041 explicit SIM_ConRelTwoState(const SIM_DataFactory *factory);
00042 virtual ~SIM_ConRelTwoState();
00043
00044 virtual SIM_ConRel *getSubConRelSubclass();
00045 virtual const SIM_ConRel
00046 *getConstSubConRelSubclass() const;
00047 virtual fpreal getStateForceSubclass() const;
00048 virtual fpreal getStateDistanceSubclass() const;
00049 virtual void makeStateTransitionSubclass(const SIM_Time &time);
00050
00051 private:
00052 static const SIM_DopDescription *getConRelTwoStateDopDescription();
00053
00054 DECLARE_STANDARD_GETCASTTOTYPE();
00055 DECLARE_DATAFACTORY(SIM_ConRelTwoState,
00056 SIM_ConRel,
00057 "Two State Constraint Relationship",
00058 getConRelTwoStateDopDescription());
00059 };
00060
00061 #endif