0
968views
What is socket API?
1 Answer
0
8views

The Socket API is an assortment of attachment calls that permit you to play out the accompanying essential correspondence capacities between application programs which are:

  • To Configure and set up connections with different users on the network.
  • It is also used to send and receive data to and from other users.
  • It also closes down connections.
  • It interrogates the network system to get names and status of relevant resources.
  • It also performs system and control functions as required.

The socket APIs are relatively small and simple. Many of the functions are similar to those used in file input/output routines such as <tt>read()</tt>, <tt>write()</tt>, and <tt>close()</tt>. The actual function calls to use depend on the programming language and socket library chosen.

IMS TCP/IP provides two TCP/IP socket application program interfaces (APIs). One interfaces to C language programs, the other to COBOL, PL/I, and System/370* assembly language programs.

C language: TCP/IP is associated with the C language and the UNIX operating system. TCP/IP Services includes C language API.

Sockets Extended API: The Sockets Extended API is used to write in COBOL, PL/I, or assembly language, or COBOL, PL/I, or assembly language programs that need to be modified to run with TCP/IP. The Sockets Extended API enables you to do this by using CALL statements. If you want to write new TCP/IP applications in COBOL, PL/I, or assembly language, you might prefer to use the Sockets Extended API. With this interface, C language is not required.

Please log in to add an answer.