DragonNest/Server/ServiceManager/SimpleServerFrame.h
2024-12-20 16:56:44 +08:00

23 lines
846 B
C++
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.


#pragma once
class CSimpleServerFrame
{
public:
CSimpleServerFrame();
virtual ~CSimpleServerFrame();
bool Open(USHORT nAcceptPort);
void Close();
virtual void Recv(SOCKET * pSocket, const char * pData, int nLen) = 0;
private:
HANDLE m_hThread;
SOCKET m_hSocket;
USHORT m_nPort;
volatile bool m_bAlive;
void ThreadMain();
static unsigned int __stdcall _threadmain(void * pParam);
};