Five examples have been provided in
IPC/TCP/demo. Each example has
detailed instructions on its use in its source file. A Makefile is provided
absolute_file_name/2 is a convenient way of finding the
path to a demonstration program. For example, to find the sibling
demonstration, try issuing the command
| ?- absolute_file_name(demo('sibling.pl'),X).
Here is a list of the example tcp programs.
server.plfrom the c-shell. If the ServerFile (see
tcp_address_from_file/2, ipc-tcp-mco-address_from_file2) for some server is
% cs x "write('hi there'),nl"
causes the server to write the string
"hi there\n" to its socket. The C
cs.c copies the socket output from the server to