|
|
|
|
|
- Different modes
- How a client application works
WINDEV includes advanced socket functions. A socket is a communication resource used by applications to communicate between two computers regardless of the type of network. This communication mode can be used, for example, to establish a communication between computers connected by Internet. WINDEV applications can manage sockets according to different modes: - WINDEV client application: the application connects to any server and exchanges data via a socket.
- WINDEV application "Simplified server ": the WINDEV application is a server, exchanging information via a socket with a single client workstation.
- WINDEV application "Standard server ": the WINDEV application is a server, exchanging information via sockets with any number of client workstations.
How a client application works A client application of a socket server connects to a standard server to exchange information via a socket. Example: A WINDEV client application can connect to a standard Internet news server. Step 1: Connect toserver To connect to a server socket, use SocketConnect. This function makes a connection request to the server. The socket is identified by its port and address. Step 2: Data exchange Once two machines have connected their sockets, a communication channel is established between them. These two machines can read from and write character strings to the socket. To read from and write to the socket of the server, the WINDEV client application must use SocketRead and SocketWrite. Step 3: End of communication To end the communication, close the socket from the client machine with SocketClose. The different steps can be represented as follows:
Remark: SocketXXX functions can also be used to manage SSL-secured sockets.. To do so, use SocketCreateSSL and SocketConnectSSL.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|