www.pudn.com > 20070204001822308.gz > mswinsockcontrol.h


#if !defined(AFX_MSWINSOCKCONTROL_H__D2405DE9_04F8_44B0_A625_3A8CDC4C209B__INCLUDED_) 
#define AFX_MSWINSOCKCONTROL_H__D2405DE9_04F8_44B0_A625_3A8CDC4C209B__INCLUDED_ 
 
#if _MSC_VER > 1000 
#pragma once 
#endif // _MSC_VER > 1000 
// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++ 
 
// NOTE: Do not modify the contents of this file.  If this class is regenerated by 
//  Microsoft Visual C++, your modifications will be overwritten. 
 
///////////////////////////////////////////////////////////////////////////// 
// CMSWinsockControl wrapper class 
 
class CMSWinsockControl : public CWnd 
{ 
protected: 
	DECLARE_DYNCREATE(CMSWinsockControl) 
public: 
	CLSID const& GetClsid() 
	{ 
		static CLSID const clsid 
			= { 0x248dd896, 0xbb45, 0x11cf, { 0x9a, 0xbc, 0x0, 0x80, 0xc7, 0xe7, 0xb7, 0x8d } }; 
		return clsid; 
	} 
	virtual BOOL Create(LPCTSTR lpszClassName, 
		LPCTSTR lpszWindowName, DWORD dwStyle, 
		const RECT& rect, 
		CWnd* pParentWnd, UINT nID, 
		CCreateContext* pContext = NULL) 
	{ return CreateControl(GetClsid(), lpszWindowName, dwStyle, rect, pParentWnd, nID); } 
 
    BOOL Create(LPCTSTR lpszWindowName, DWORD dwStyle, 
		const RECT& rect, CWnd* pParentWnd, UINT nID, 
		CFile* pPersist = NULL, BOOL bStorage = FALSE, 
		BSTR bstrLicKey = NULL) 
	{ return CreateControl(GetClsid(), lpszWindowName, dwStyle, rect, pParentWnd, nID, 
		pPersist, bStorage, bstrLicKey); } 
 
// Attributes 
public: 
 
// Operations 
public: 
	long GetProtocol(); 
	void SetProtocol(long nNewValue); 
	CString GetRemoteHostIP(); 
	CString GetLocalHostName(); 
	CString GetLocalIP(); 
	long GetSocketHandle(); 
	long GetRemotePort(); 
	void SetRemotePort(long nNewValue); 
	long GetLocalPort(); 
	void SetLocalPort(long nNewValue); 
	short GetState(); 
	long GetBytesReceived(); 
	void Connect(const VARIANT& RemoteHost, const VARIANT& RemotePort); 
	void Listen(); 
	void Accept(long requestID); 
	void SendData(const VARIANT& data); 
	void GetData(VARIANT* data, const VARIANT& type, const VARIANT& maxLen); 
	void PeekData(VARIANT* data, const VARIANT& type, const VARIANT& maxLen); 
	void Close(); 
	void Bind(const VARIANT& LocalPort, const VARIANT& LocalIP); 
	CString GetRemoteHost(); 
	void SetRemoteHost(LPCTSTR lpszNewValue); 
}; 
 
//{{AFX_INSERT_LOCATION}} 
// Microsoft Visual C++ will insert additional declarations immediately before the previous line. 
 
#endif // !defined(AFX_MSWINSOCKCONTROL_H__D2405DE9_04F8_44B0_A625_3A8CDC4C209B__INCLUDED_)