//ClientTunnel.h /////////////////////////////////////////////////////////////////////////////// #ifndef _CLIENT_TUNNEL_H_ #define _CLIENT_TUNNEL_H_ #include "IClientImpl.h" #include "Client2SrvType.h" class CClientTunnel { public: CClientTunnel(); virtual ~CClientTunnel(); public: static TransportStatus Transport_Init(); static TransportStatus Transport_UnInit(); int net_OpenSocket( IN CONST ETransportType eType, IN CONST unsigned short usPort, IN LPTRANSPORT_EVENT eventHandler, void *pContext); void net_CloseSocket(); int net_Connect(IN CONST unsigned long ulIPValue, IN CONST unsigned short usPort); int net_Connect(IN LPCTSTR strAddr, LPCTSTR strPort); unsigned long net_Send( IN void *pHeader, IN void *pMessage, IN CONST unsigned long ulDataLen); public: LPTRANSPORT_EVENT m_eventHandler; void *m_pContext; private: INT m_nIndex; IClientImpl m_Client; }; #endif /*_CLIENT_TUNNEL_H_*/