ySocket

Class for running an Internet socket using C++.

Server socket

#include "ySocket.h"

int main(void)
{
	yServerSocket server;
	server.run();

	return 0;
}

Compile

g++ server.cpp ySocket.cpp -o server

Client socket

#include "ySocket.h"

int main(void)
{
	yClientSocket client;
	client.run("Message to server");

	return 0;
}

Compile

g++ client.cpp ySocket.cpp -o client

Execution

You must execute the server program and then the client program.

GitHub

View Github