C# Class ServerNetworkConnections.TCPServerConnector

Class that encapsulates the workings of a TcpListener
Show file Open project: bakacaptain/istalkapp Class Usage Examples

Public Methods

Method Description
Start ( ) : void

Method to make the listener start listening

Stop ( ) : void

Method to make the listening stop listening

TCPServerConnector ( UInt16 port, AbstractMessageParser parser ) : System

Constructor for TCPServerConnector

waitForConnection ( ) : TCPConnection

A blocking method that listens for an incoming TCP connection and returns it.

Method Details

Start() public method

Method to make the listener start listening
public Start ( ) : void
return void

Stop() public method

Method to make the listening stop listening
public Stop ( ) : void
return void

TCPServerConnector() public method

Constructor for TCPServerConnector
public TCPServerConnector ( UInt16 port, AbstractMessageParser parser ) : System
port System.UInt16 A UInt16 with the port.
parser AbstractMessageParser
return System

waitForConnection() public method

A blocking method that listens for an incoming TCP connection and returns it.
public waitForConnection ( ) : TCPConnection
return TCPConnection