clientsocket.h

来自「面向软件工程的Visual C++网络程序开发」· C头文件 代码 · 共 75 行

H
75
字号
#if !defined(AFX_CLIENTSOCKET_H__17092276_0DD4_4A9B_A150_4AA8D5A4B14D__INCLUDED_)
#define AFX_CLIENTSOCKET_H__17092276_0DD4_4A9B_A150_4AA8D5A4B14D__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// ClientSocket.h : header file
//
/////////////////////////////////////////////////////////////////////////////
// CClientSocket command target
class CClientDlg;

class CClientSocket : public CAsyncSocket
{
// Attributes

// Operations
public:
	CClientSocket(CClientDlg* pDlg);
	virtual ~CClientSocket();

// Overrides
public:
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CClientSocket)
	public:
	virtual void OnConnect(int nErrorCode);
	virtual void OnReceive(int nErrorCode);
	virtual void OnClose(int nErrorCode);
	//}}AFX_VIRTUAL

	// Generated message map functions
	//{{AFX_MSG(CClientSocket)
		// NOTE - the ClassWizard will add and remove member functions here.
	//}}AFX_MSG

// Implementation
protected:
	int  SendLoginInfo();
	void OnOffline(WORD wType);
	void OnReceiveMessage();
	void OnReceiveUserDel();
	void OnReceiveUserAdd();
	void OnReceiveUserList();
	CClientDlg*	m_pMainWnd;
};

/////////////////////////////////////////////////////////////////////////////

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_CLIENTSOCKET_H__17092276_0DD4_4A9B_A150_4AA8D5A4B14D__INCLUDED_)





















⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?