DragonNest/Common/NetworkLib/SendThread.h
2024-12-20 16:56:44 +08:00

29 lines
No EOL
962 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
#if defined(_SERVER)
#include "Thread.h"
class CSocketContext;
class CSendThread:public Thread
{
public:
CSendThread();
virtual ~CSendThread();
void Run();
void PushSendQueue( CSocketContext* pSocketContext );
private:
CSocketContext* PopSendQueue();
void FlushAllSendQueue();
HANDLE m_SendQueueEvent;
CSyncLock m_SendQueueLock;
std::queue<CSocketContext*> m_SendQueue;
};
#endif // #if defined(_SERVER)