ContRap-Core
Public Member Functions | Protected Attributes

crp::ServerSocket Class Reference

Class ServerSocket is a platform independent server socket implementation. More...

#include <socket.h>

Inheritance diagram for crp::ServerSocket:
crp::Socket

Public Member Functions

 ServerSocket (int port)
 Creates a server socket on the given port.
 ~ServerSocket ()
 Disconnects from the socket and releases the memory.
void connect ()
 Connects to the socket.
ClientSocketreceive ()
 Listens a new client connection.

Protected Attributes

int port
 Port number of the socket.

Detailed Description

Class ServerSocket is a platform independent server socket implementation.


Constructor & Destructor Documentation

crp::ServerSocket::ServerSocket ( int  port)

Creates a server socket on the given port.

crp::ServerSocket::~ServerSocket ( )

Disconnects from the socket and releases the memory.


Member Function Documentation

void crp::ServerSocket::connect ( )

Connects to the socket.

ClientSocket* crp::ServerSocket::receive ( )

Listens a new client connection.

This method is blocking.

Returns:
New client connection.

Field Documentation

int crp::ServerSocket::port [protected]

Port number of the socket.


The documentation for this class was generated from the following file: