21#ifndef GF_SOCKET_SELECTOR_H
22#define GF_SOCKET_SELECTOR_H
34#include "SocketGuard.h"
35#include "SocketTypes.h"
39#ifndef DOXYGEN_SHOULD_SKIP_THIS
90 std::vector<pollfd>::iterator find(
Socket& socket);
93 std::vector<pollfd> m_fds;
97#ifndef DOXYGEN_SHOULD_SKIP_THIS
A guard to handle library initialization.
Definition: SocketGuard.h:42
A network socket.
Definition: Socket.h:41
A socket selector.
Definition: SocketSelector.h:50
void removeSocket(Socket &socket)
Remove a socket from the selector.
SocketSelectorStatus wait(Time duration=seconds(-1))
Wait for an event of the set of sockets.
SocketSelector()
Constructor.
void addSocket(Socket &socket)
Add a socket to the selector.
bool isReady(Socket &socket)
Tell if the provided socket is ready.
void clear()
Clear all the sockets in the selector.
Represents a time value.
Definition: Time.h:65
SocketSelectorStatus
The status of the selector.
Definition: SocketTypes.h:98
The namespace for gf classes.