Network/TcpClient: Add PollForConnected

This commit is contained in:
Lynix
2018-10-01 23:04:53 +02:00
parent dad2dbae1c
commit 67c56b2aba
7 changed files with 159 additions and 119 deletions

View File

@@ -40,7 +40,6 @@ namespace Nz
static void Close(SocketHandle handle);
static SocketState Connect(SocketHandle handle, const IpAddress& address, SocketError* error);
static SocketState Connect(SocketHandle handle, const IpAddress& address, UInt64 msTimeout, SocketError* error);
static bool Initialize();
@@ -61,6 +60,7 @@ namespace Nz
static std::size_t QuerySendBufferSize(SocketHandle handle, SocketError* error = nullptr);
static unsigned int Poll(PollSocket* fdarray, std::size_t nfds, int timeout, SocketError* error);
static SocketState PollConnection(SocketHandle handle, const IpAddress& address, UInt64 msTimeout, SocketError* error);
static bool Receive(SocketHandle handle, void* buffer, int length, int* read, SocketError* error);
static bool ReceiveFrom(SocketHandle handle, void* buffer, int length, IpAddress* from, int* read, SocketError* error);