#ifndef SERVERH
#define SERVERH

#include "stdafx.h"

class SerwerTCPAsync : public CSocket
{
public:
	SerwerTCPAsync(CEdit * _edit,int _port) 
	{
		CSocket::CSocket();
		edit = _edit;
		port = _port;
		klient = NULL;
	}
	~SerwerTCPAsync() {if ( klient != NULL) delete klient;}
	void Start();
	virtual void OnAccept(int nErrorCode);
	virtual void OnReceive(int nErrorCode);
private:
	CAsyncSocket * klient;
	CEdit  * edit;
	int port;
};

#endif