hd

FlowTemplate.h 1.8KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. /*************************************************************************
  2. 【文件名】 FlowTemplate.h
  3. 【功能模块和目的】 流程模板类头文件
  4. 【开发者及日期】 郑石诺 2015/01/27
  5. 【版本】 V1.0.0
  6. 【版权信息】 Copyright (C)2015 河南华谊网络科技有限公司
  7. 【更改记录】
  8. *************************************************************************/
  9. #pragma once
  10. class IFlowDataProvider;
  11. class CCellBase;
  12. /*************************************************************************
  13. 【类名】 CFlowTemplate
  14. 【功能】
  15. 【接口说明】 流程模板类
  16. 【开发者及日期】 郑石诺 2015/01/27
  17. 【版本】 V1.0.0
  18. 【版权信息】 Copyright (C)2015 河南华谊网络科技有限公司
  19. 【更改记录】
  20. *************************************************************************/
  21. class CFlowTemplate
  22. {
  23. public:
  24. CFlowTemplate(void);
  25. ~CFlowTemplate(void);
  26. FlowType type(void) const { return m_Type; }
  27. const CString& name(void) const { return m_Name; }
  28. int concurrency(void) const { return m_Concurrency; }
  29. bool fillData(IFlowDataProvider& Provider); // 解析流程文件为数据字段赋值
  30. void accept(int CellPos, CCellBase* pCell); // 填充cell map
  31. int getCellPos(const CString& CellName); // 根据节点名称获取节点编号
  32. CCellBase* findCell(int CellPos); // 根据Cell节点号获取Cell
  33. int matchLine(UINT TrunkId); // 匹配线路0:不匹配;1:匹配;-1为默认流程
  34. bool matchCaller(LPCTSTR Caller); // 根据主叫号码分析流程的适用性
  35. bool isMatchedPreCall(void) const; // 是否匹配预测呼叫
  36. private:
  37. void __release(void); // 释放所有cell
  38. private:
  39. FlowType m_Type; // 流程类型
  40. int m_Concurrency; // 并发量
  41. CString m_Name; // 流程名字
  42. CString m_MatchedNum; // 当前流程匹配的被叫号码
  43. CString m_MatchedLine; // 当前流程关联的外线ID列表,以 | 进行分隔, -1 表示本流程为默认流程
  44. CMap<int, int, CCellBase*, CCellBase*> m_CellMap; // cell链表
  45. };