TCP

From Clean
Revision as of 12:25, 6 July 2010 by Bas Lijnse (talk | contribs) (Created page with 'The TCP library contains functions and data structures to write Clean programs that communicate by means of the TCP protocol (transmission control protocol). This protocol lets …')
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

The TCP library contains functions and data structures to write Clean programs that communicate by means of the TCP protocol (transmission control protocol). This protocol lets you establish channels to send and receive data via a network.

The library can be divided into two parts: The synchronous and the asynchronous part.

The synchronous part is applicable in non event driven programs (e.g. simple console applications) as well as in event driven programs (GUI-applications using the Object I/O Library). Many function calls can _block_ the whole Clean program until the corresponding action has been completed. For instance synchronously receiving data via a channel can block for a long time until the data arrives via the network. In that time the program does not proceed in it's execution.

Although the synchronous part is easier to use it's blocking behaviour could raise problems in conjunction with GUI (graphical user interface) programs. These problems can be circumvented by using the asynchronous (event driven) part of this library.

The library further offers acces to the DNS (domain name service).

The library is integrated with the Object I/O library. The tutorial to the Object I/O library contains the documentation for this package.