Implements a listening Socket server.
More...
#include <SocketServer.h>
|
| | SocketServer (int port) throw ( SocketException ) |
| |
| | SocketServer () |
| |
| virtual | ~SocketServer () |
| |
| void | accept (SocketServer &) throw ( SocketException ) |
| |
| void | accept (SocketServer &newSocket, int timeoutMillis) throw ( SocketException ) |
| | accept with timeout More...
|
| |
| virtual | ~Socket () |
| |
| int | send (const char *buffer, size_t bufferLength) const throw ( SocketException& ) |
| | If return value is -1, check errno. More...
|
| |
| int | sendall (const char *buffer, size_t bufferLength) |
| | Like send but making sure the whole requested buffer is sent out. More...
|
| |
| int | recv (char *buffer, size_t bufferLength) const throw ( SocketException& ) |
| | Blocking read. More...
|
| |
| int | recv (char *buffer, size_t bufferLength, int timeoutMillis) throw ( SocketException& ) |
| | Socket read with timeout. More...
|
| |
| int | setTimeout (const int milliseconds) |
| |
| int | close () |
| |
| int | getPort () |
| |
| int | getDescriptor () |
| | exposes the socket descriptor to facilitate direct operations More...
|
| |
|
| | Socket () |
| |
| void | create () throw ( SocketException& ) |
| |
| void | bind (const int port) throw ( SocketException& ) |
| |
| void | listen () const throw ( SocketException& ) |
| |
| void | accept (Socket &newSocket) throw ( SocketException& ) |
| |
| void | accept (Socket &newSocket, int timeoutMillis) throw ( SocketException& ) |
| | accept with given timeout, which could be 0 for completely non-blocking behavior More...
|
| |
| void | connect (const char *host, const int port) throw ( SocketException& ) |
| |
| void | connect (const char *host, const int port, int timeoutMillis) throw ( SocketException& ) |
| | connect with timeout. More...
|
| |
| void | setNonBlocking (const bool nonBlocking) throw ( SocketException& ) |
| |
| bool | isValid () const |
| |
| void | setTimeval (const int milliseconds, struct timeval &tv) |
| |
Implements a listening Socket server.
| SocketServer::SocketServer |
( |
| ) |
|
|
inline |
| virtual SocketServer::~SocketServer |
( |
| ) |
|
|
inlinevirtual |
The documentation for this class was generated from the following files: