Try OpenEdge Now
skip to main content
Programming Interfaces
External Program Interfaces : Sockets : Overview of tasks to implement ABL sockets
 

Overview of tasks to implement ABL sockets

Socket programming can be typically divided into three parts:
*Server programming tasks
*Client programming tasks
*Tasks common to both clients and servers
This section summarizes the tasks for programming sockets in ABL using the same framework. The sections that follow describe each of these tasks in more detail.
The following table lists socket programming tasks by application function, indicates whether each task is required for implementing socket communications, and provides a reference to a following section for more information on the task.
Table 66. Summary of socket programming tasks
Application function
Tasks
Socket server
*Create a server socket object and enable it to listen for connections (CONNECT events) on a specified port (required). See Implementingan ABL socket server.
*Define a CONNECT event procedure to respond to CONNECT events and return the socket object handle created for each connection (required). See Listening and responding to connection requests.
*Make the server socket temporarily insensitive to CONNECT events. See Managingthe server socket.
*Disable the server socket from listening for new socket connections. See Managingthe server socket.
*Delete the server socket object. See Managingthe server socket.
Socket client
*Create a socket object to read and write data, and connect it to a port on a socket server (required). See Implementingan ABL socket client.
Client or server
*Define and initialize a MEMPTR variable (required to read or write data on a socket). See Defining and initializing MEMPTR variables.
*Test whether data is available to read on a socket. See Data detection using the procedural model.
*Define a READ-RESPONSE event procedure to respond to data coming in on a socket connection. See Data detection using the event-driven model.
*Read data on a socket and test for the number of bytes read for each read operation. See Readingdata on a socket.
*Write data on a socket and test for the number of bytes written for each write operation. see Writingdata on a socket.
*Marshall data into a MEMPTR buffer for writing on a socket and unmarshall data from a MEMPTR buffer after reading on a socket. see Marshalling and unmarshalling data for socket I/O.
*Test whether a socket object is connected. see Managing sockets and their connections.
*Make a socket temporarily insensitive to READ-RESPONSE events. see Managing sockets and their connections.
*Set and get socket options. see Managing sockets and their connections.
*Obtain the local and remote host IP addresses and port numbers involved in a socket connection. see Managing sockets and their connections.
*Disconnect a socket object from its remote host and port. See Managing sockets and their connections.
*Delete socket objects. see Managing sockets and their connections.
Socket security
*Configure socket servers and clients for SSL. See ImplementingABL socket security.
*Enable SSL server connections. See EnablingSSL server connections.
*Connect an SSL client to an SSL server. See Connecting an SSL client to an SSL server.
*Invoke socket operations. See Invoking socket operations for SSL sessions.
Note: SSL incurs heavy performance penalties, depending on the client, server, and network resources and load.