| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556 |
- /*************************************************************************
- 【文件名】 FaxChannel.h
- 【功能模块和目的】 传真通道类头文件
- 【开发者及日期】 郑石诺 2015/05/18
- 【版本】 V1.0.0
- 【版权信息】 Copyright (C)2015 河南华谊网络科技有限公司
- 【更改记录】
- *************************************************************************/
- #pragma once
- class COneLeg;
- class CIpmChannel;
- /*************************************************************************
- 【类名】 CFaxChannel
- 【功能】
- 【接口说明】 传真通道类
- 【开发者及日期】 郑石诺 2015/05/18
- 【版本】 V1.0.0
- 【版权信息】 Copyright (C)2015 河南华谊网络科技有限公司
- 【更改记录】
- *************************************************************************/
- class CFaxChannel
- {
- public:
- CFaxChannel(int ChanNo);
- ~CFaxChannel(void);
- bool open(void);
- void close(void);
- bool isFree(void) const { return m_state == FS_IDLE; }
- bool send(COneLeg* pLeg, LPCTSTR FaxFile);
- bool recv(COneLeg* pLeg, LPCTSTR FaxFile);
- bool stop(void);
- void onDevEvent(METAEVENT* pMetaEvent);
- private:
- void __release(bool FaxResult);
- void __onFaxError(void);
- void __onFaxEnd(void);
- private:
- typedef enum
- {
- FS_IDLE = 0,
- FS_SEND = 1,
- FS_RECV = 2
- } FaxState;
- int m_ChanNo;
- int m_Handle;
- FaxState m_state;
- COneLeg* m_pLeg;
- CIpmChannel* m_pIpmChan;
- };
|