eis/inc/pmg/Plan.h

77 lines
1.7 KiB
C++
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

/*********************************************************************
*
* 版权所有: Shanghai Baosight Software Co., Ltd.
*
* 概述:
* 版本历史
* 1.0 2014-08-18 jamie 增加注释
*
*********************************************************************/
#ifndef _PLAN_H
#define _PLAN_H
#include <common/BasicStruct.h>
#include <glob/AutoTele.h>
#include <Ice/BuiltinSequences.h>
#include <list>
#include <cda/ScheduleDAO.h>
#include <glob/DataAccess.h>
#include <dao/LimitsMag.h>
#include <dao/DBMag.h>
#include <cda/AlarmLog.h>
#include <common/L2Event.h>
using namespace baosight;
class Plan
{
public:
Plan(AutoTele* tele,DataAccess* dAccess);
virtual ~Plan();
//请求计划
virtual int request(int eventNo,const Ice::ByteSeq& seq) = 0;
//接收计划
virtual int receive(int eventNo,const Ice::ByteSeq& seq) = 0;
//撤销计划
virtual int revoke(int eventNo,const Ice::ByteSeq& seq) = 0;
//创建计划
virtual int create(int eventNo,const Ice::ByteSeq& seq) = 0;
//调整计划
virtual int adjust(int eventNo,const Ice::ByteSeq& seq) = 0;
//处理L3应答(L2L3正负应答
virtual int answer(int eventNo,const Ice::ByteSeq& seq,int result = 0) = 0;
protected:
virtual short sendToL3(int eventNo,const string & strmsg = "");
//检查电文钢卷号是否正常
virtual int checkCoilID();
public:
static std::list<std::string> ml_CoilId; //计划钢卷序列
protected:
string m_planNo; //计划号
string m_coilId; //钢卷号
string m_rollId; //轧辊号
S_COILINFO m_coilInfo; //钢卷信息
S_ROLLINFO m_rollInfo; //轧辊信息
protected:
string m_retReason; //处理原因
protected:
DataAccess* mp_dataAccess;
AutoTele* mp_tele;
protected:
char almsg[512];
};
#endif