00001 00002 #ifndef __QDAQSTATECOMMAND_HH_ 00003 #define __QDAQSTATECOMMAND_HH_ 00004 00005 #include <string> 00006 #include "QCuore.hh" 00007 #include "QCommand.hh" 00008 #include "QDaqCommonDefs.hh" 00009 00010 00019 class QDaqStateCommand : public QCommand 00020 { 00021 public: 00022 00024 QDaqStateCommand(); 00025 00027 QDaqStateCommand(const std::string& which); 00028 00030 virtual ~QDaqStateCommand(); 00031 00033 virtual void Execute(); 00034 00036 virtual void CheckParams(); 00037 00038 private: 00039 00044 enum QDaqCommandCode { 00045 QNoCmd=0, 00046 QStartCmd=1, 00047 QStopCmd=2, 00048 QPauseCmd=4, 00049 QResumeCmd=8 00050 }; 00051 00052 std::string fCommand; 00053 QDaqCommandCode fCommandCode; 00055 int fSettingsBasket; 00056 int fShifterSet; 00057 int fRun; 00058 std::string fComments; 00063 bool CheckCommandState(QDaqCommonDefs::QDaqState daqState) const; 00064 00066 void CheckStartParams(); 00067 00069 void CheckStopParams(); 00070 }; 00071 #endif