chatsocket.h

来自「这是一个很好实现的网络聊天程序」· C头文件 代码 · 共 60 行

H
60
字号
#if !defined(AFX_CHATSOCKET_H__A2863DBF_FFFB_4E0C_832B_B1052834A238__INCLUDED_)
#define AFX_CHATSOCKET_H__A2863DBF_FFFB_4E0C_832B_B1052834A238__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// chatSocket.h : header file
//


class CChatserverView;
class CMesg;
/////////////////////////////////////////////////////////////////////////////
// CchatSocket command target

class CchatSocket : public CSocket
{
// Attributes
public:

// Operations
public:
	CchatSocket(CChatserverView *pview);
	virtual ~CchatSocket();
public:
   CSocketFile  *m_pfile;
   CArchive     *m_in;
   CArchive     *m_out;
   CString      name;
public:
   CChatserverView  *m_pview;

// Overrides
public:
	void Abort();
	void init();
	void receivemessage(CMesg *msg);
	void sendmessage(CMesg *msg);
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CchatSocket)
	public:
	virtual void OnReceive(int nErrorCode);
	//}}AFX_VIRTUAL

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

// Implementation
protected:
};

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

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

#endif // !defined(AFX_CHATSOCKET_H__A2863DBF_FFFB_4E0C_832B_B1052834A238__INCLUDED_)

⌨️ 快捷键说明

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