30 #include <sys/socket.h>
31 #include <netinet/in.h>
32 #include <arpa/inet.h>
60 tcp_client(
const char*ip,
int port,
bool async_comm=
false);
93 int Send(
char*data,
int size);
107 int Receive(
char*data,
int size,
bool peek=
false,
int*number=NULL,
int flags=0);
117 int perr(
const char*text);
141 struct sockaddr_in server;
bool connected
Status of the connection.
bool async
Asynchronous comm.
int sock
Socket identification.
int ret
Return value for functions.
This class implements the TCP/IP client communication.