simulavr  1.1.0
Socket Class Reference

#include <mysocket.h>

Inheritance diagram for Socket:

Public Member Functions

 Socket (int port)
 
 ~Socket ()
 
ssize_t Read (std::string &a)
 
void Write (const std::string &s)
 
ssize_t Poll ()
 
void Write (const char *in)
 

Private Member Functions

void OpenSocket (int port)
 

Private Attributes

int sock
 
int conn
 

Detailed Description

Todo:
The implementation of Socket has to be cleaned. In the moment, the Socket implementation for MingW acts only as client, the unix implementation could act also as server, but is this necessary?

Definition at line 45 of file mysocket.h.

Constructor & Destructor Documentation

◆ Socket()

Socket::Socket ( int  port)

◆ ~Socket()

Socket::~Socket ( )

Member Function Documentation

◆ OpenSocket()

void Socket::OpenSocket ( int  port)
private

◆ Poll()

ssize_t Socket::Poll ( )

◆ Read()

ssize_t Socket::Read ( std::string &  a)

◆ Write() [1/2]

void Socket::Write ( const std::string &  s)

Referenced by Write().

◆ Write() [2/2]

void Socket::Write ( const char *  in)
inline

Definition at line 65 of file mysocket.h.

References Write().

Member Data Documentation

◆ conn

int Socket::conn
private

Definition at line 54 of file mysocket.h.

◆ sock

int Socket::sock
private

Definition at line 54 of file mysocket.h.


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