Overview Module Function Class Tea 3.2.4 Reference Documentation
© 2009 PDM&FC

Class TServerSocketPlain

Instances of TServerSocketPlain are used as server sockets that listen for connections in a given port. For each connection accepted by calling the accept method a new TSocket is created. This TSocket represents the connection with the client socket.

Method Summary
accept
         Waits for an incoming connection.
close
         Closes this server socket.
constructor portNumber
         Initializes the server socket.

Method Detail

accept

TServerSocketPlain accept

Waits for an incoming connection.

Returns:
A new TSocketPlain object associated with the connection.

This method blocks until a connection is made to the port the server socket is listening in.

close

TServerSocketPlain close

Closes this server socket.

Returns:
A reference to the object for which the method was invoked.


constructor

TServerSocketPlain constructor portNumber

Initializes the server socket.

Parameters:
portNumber - Integer representing the port number where the server socket will listen for connections.



Overview Module Function Class Tea 3.2.4 Reference Documentation
© 2009 PDM&FC
Report a bug or request new features
© 2009