You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

38 lines
1.2 KiB
C

#pragma once
#include "GlobalDefine.h"
#include "LogMgr.h"
//ÿ<><C3BF><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ƽ̨<C6BD>ƶ<EFBFBD><C6B6>ĵ<EFBFBD>,<2C><><EFBFBD><EFBFBD><E6B4A2>ʵ<EFBFBD>ʵĹ<CAB5><C4B9><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
//command ģʽ
class CWorkCmd
{
public:
CWorkCmd(void);
virtual ~CWorkCmd(void);//BUG 2015-12-21
virtual bool Excute()=0;
virtual void WirteLog(){};
virtual CString GetWorkCmdInfoStr(){return "";};
public:
void CanNotCancel(){m_bCancel = false;};//<2F><><EFBFBD>ܱ<EFBFBD>ȡ<EFBFBD><C8A1>
bool Work(bool Cancel);
void SetFrontDelay(int t){m_FrontDelay = t;};
void SetAfterDelay(int t){m_AfterDelay = t;};
bool IsbShowLog(){return m_bShowLog;};
void NotShowLog(){m_bShowLog = false;};
void UseSleepDelay(){m_bUseSleepDelay = true;};
bool IsbExcuted(){return m_bExcuted;};
void SetbExcuting(bool b){m_bExcuting = b;};
bool IsbExcuting(){return m_bExcuting;};
protected:
int m_FrontDelay;//ָ<><D6B8>ִ<EFBFBD><D6B4>֮ǰ<D6AE><C7B0><EFBFBD><EFBFBD>ʱ(<28><>λ: <20><><EFBFBD><EFBFBD>)
int m_AfterDelay;//ָ<><D6B8>ִ<EFBFBD><D6B4>֮<EFBFBD><D6AE><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʱ(<28><>λ: <20><><EFBFBD><EFBFBD>)
bool m_bCancel;//ָ<><D6B8><EFBFBD>Ƿ<EFBFBD><C7B7><EFBFBD><EFBFBD><EFBFBD>ȡ<EFBFBD><C8A1>(<28><><EFBFBD><EFBFBD>;ָֹͣ<D6B9><D6B8><EFBFBD><EFBFBD>ִ<EFBFBD>к<EFBFBD><D0BA><EFBFBD><EFBFBD>е<EFBFBD>ָ<EFBFBD><EFBFBD><EEBBB9><EFBFBD><EFBFBD>Ҫִ<D2AA><D6B4>)
bool m_bShowLog;//<2F>Ƿ<EFBFBD><C7B7><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>־
bool m_bUseSleepDelay;//ʹ<><CAB9>sleep <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʱ
bool m_bExcuted;//<2F>Ƿ<EFBFBD><C7B7>Ѿ<EFBFBD><D1BE><EFBFBD>ִ<EFBFBD><D6B4>
bool m_bExcuting;//<2F><><EFBFBD>ڱ<EFBFBD>ִ<EFBFBD><D6B4>
};