![]() |
Gray C++ Libraries
0.0.2
A set of C++ libraries for MSVC, GNU on Windows, WinCE, Linux
|
#include <cNetServer.h>
Public Member Functions | |
| cNetServerGroup (cNetServer &server) | |
| virtual | ~cNetServerGroup () |
| const char * | get_ServerName () const |
| ITERATE_t | get_ClientQty () const |
| bool | RemoveClient (cNetServerConnection *pClient) |
| void | MoveClientToGroup (cNetServerConnection *pClient) |
| void | MoveClientToClose (cNetServerConnection *pClient) |
Public Member Functions inherited from Gray::cStreamStats | |
| void | Add (const cStreamStats &n) |
Public Attributes | |
| cNetServer & | m_server |
| My top level cNetServer owner/parent. More... | |
| cValueStatsRate< float > | m_TickLatency |
| How long did the last OnTickSelect and OnTickClients take ? TIMESYS_t. More... | |
Public Attributes inherited from Gray::cStreamStats | |
| cStreamStat | m_StatOut |
| cStreamStat | m_StatInp |
Protected Member Functions | |
| HRESULT | OnClientWrite (cNetServerConnection *pClient) |
| virtual HRESULT | OnClientRead (cNetServerConnection *pClient) |
| HRESULT | OnTickSelect (TIMESYSD_t tWaitMax, cNetSocketSet &readfds, cNetSocketSet &writefds) |
| virtual void | OnTickClients () |
Protected Attributes | |
| cThreadLockArrayHash< cNetServerConnection > | m_aConnections |
| Collection of active clients. sorted by socket id. More... | |
A collection of client connections to the server. We can assign clients to one of multiple groups/threads for processing of the client stream. Distribute server loading on multiple threads to best take advantage of multi core servers.
| GrayLib::cNetServerGroup::cNetServerGroup | ( | cNetServer & | server | ) |
|
virtual |
|
inline |
how many connected clients do i have? includes unresolved new connections.
| const char * GrayLib::cNetServerGroup::get_ServerName | ( | ) | const |
| void GrayLib::cNetServerGroup::MoveClientToClose | ( | cNetServerConnection * | pClient | ) |
Move this client to the close group.
| void GrayLib::cNetServerGroup::MoveClientToGroup | ( | cNetServerConnection * | pClient | ) |
Move pServerConnection to this cNetServerGroup (or thread).
|
protectedvirtual |
Data is ready for read on a client connection. FD_READ
Reimplemented in GrayLib::cNetServer.
|
protected |
Data is ready for writing on a client connection. FD_WRITE
|
protectedvirtual |
Give the clients a periodic tick. Call this manually if using Async notifications.
Reimplemented in GrayLib::cNetServer.
|
protected |
| bool GrayLib::cNetServerGroup::RemoveClient | ( | cNetServerConnection * | pClient | ) |
|
protected |
Collection of active clients. sorted by socket id.
| cNetServer& GrayLib::cNetServerGroup::m_server |
My top level cNetServer owner/parent.
| cValueStatsRate<float> GrayLib::cNetServerGroup::m_TickLatency |
How long did the last OnTickSelect and OnTickClients take ? TIMESYS_t.