Ginga  0.13.6
 All Classes Namespaces Functions Variables
Public Member Functions | List of all members
br::pucrio::telemidia::ginga::core::system::compat::TCPServerSocket Class Reference

#include <PracticalSocket.h>

Inheritance diagram for br::pucrio::telemidia::ginga::core::system::compat::TCPServerSocket:
Inheritance graph
[legend]
Collaboration diagram for br::pucrio::telemidia::ginga::core::system::compat::TCPServerSocket:
Collaboration graph
[legend]

Public Member Functions

 TCPServerSocket (unsigned short localPort, int queueLen=5) throw (SocketException)
 
 TCPServerSocket (const string &localAddress, unsigned short localPort, int queueLen=5) throw (SocketException)
 
TCPSocketaccept () throw (SocketException)
 
- Public Member Functions inherited from br::pucrio::telemidia::ginga::core::system::compat::Socket
 ~Socket ()
 
string getLocalAddress () throw (SocketException)
 
unsigned short getLocalPort () throw (SocketException)
 
void setLocalPort (unsigned short localPort) throw (SocketException)
 
void setLocalAddressAndPort (const string &localAddress, unsigned short localPort=0) throw (SocketException)
 

Additional Inherited Members

- Static Public Member Functions inherited from br::pucrio::telemidia::ginga::core::system::compat::Socket
static void cleanUp () throw (SocketException)
 
static unsigned short resolveService (const string &service, const string &protocol="tcp")
 
- Protected Member Functions inherited from br::pucrio::telemidia::ginga::core::system::compat::Socket
 Socket (int type, int protocol) throw (SocketException)
 
 Socket (int sockDesc)
 
- Protected Attributes inherited from br::pucrio::telemidia::ginga::core::system::compat::Socket
int sockDesc
 

Detailed Description

TCP socket class for servers

Constructor & Destructor Documentation

br::pucrio::telemidia::ginga::core::system::compat::TCPServerSocket::TCPServerSocket ( unsigned short  localPort,
int  queueLen = 5 
)
throw (SocketException
)

Construct a TCP socket for use with a server, accepting connections on the specified port on any interface

Parameters
localPortlocal port of server socket, a value of zero will give a system-assigned unused port
queueLenmaximum queue length for outstanding connection requests (default 5)
Exceptions
SocketExceptionthrown if unable to create TCP server socket
br::pucrio::telemidia::ginga::core::system::compat::TCPServerSocket::TCPServerSocket ( const string &  localAddress,
unsigned short  localPort,
int  queueLen = 5 
)
throw (SocketException
)

Construct a TCP socket for use with a server, accepting connections on the specified port on the interface specified by the given address

Parameters
localAddresslocal interface (address) of server socket
localPortlocal port of server socket
queueLenmaximum queue length for outstanding connection requests (default 5)
Exceptions
SocketExceptionthrown if unable to create TCP server socket

Member Function Documentation

TCPSocket * br::pucrio::telemidia::ginga::core::system::compat::TCPServerSocket::accept ( )
throw (SocketException
)

Blocks until a new connection is established on this socket or error

Returns
new connection socket
Exceptions
SocketExceptionthrown if attempt to accept a new connection fails

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