61 void bind(
const string&
ip,
const unsigned int port);
86 #if defined(__MINGW32__) && !defined(__MINGW64__)
88 #define inet_pton inet_pton6
89 #define inet_ntop inet_ntop6
90 size_t strlcpy(
char* __restrict dst,
const char* __restrict src,
size_t siz);
91 int inet_pton4(
const char* src,
void* dst);
92 int inet_pton6(
int af,
const char* src,
void* dst);
93 char* inet_ntop4(
const void* src,
char* dst,
size_t size);
94 char* inet_ntop6(
int af,
const void* src,
char* dst,
size_t size);
Interface to kernel event mechanismns.
Base class of network sockets.
void bind(const string &ip, const unsigned int port)
Binds a socket to local ip and port.
virtual void close()
Closes the socket.
virtual void shutdown()
shuts socket down for reading and writing
static IpVersion determineIpVersion(const string &ip)
Determine IP version.
const string & getAddress()
returns the end points ip address
void setNonBlocked()
sets the socket non blocked
const unsigned int getPort()
returns the end points port
virtual ~NetworkSocket()
public destructor
NetworkSocket()
Protected constructor.
#define FORBID_CLASS_COPY(CLASS)