Cisco Cisco IOS Software Release 12.2(15)T Guide Du Développeur
5-3
Cisco Gatekeeper External Interface Reference, Version 4.2
Cisco IOS Release 12.2(15)T
Chapter 5 Gatekeeper API Functions and Structures
Gatekeeper API Functions
–
TCP_ADDRESS_NOT_AVAIL—Specified local IP address is not available on the local
machine.
machine.
–
TCP_BIND_ERROR—Error was encountered in setting up the server socket.
–
TCP_LISTEN_ERROR—Error was encountered in setting up the server socket.
–
TCP_NONBLOCK_ERROR—Error was encountered when setting up the socket for
nonblocking I/O.
nonblocking I/O.
•
A boolean value that allows the application to specify if the socket I/O should be nonblocking or
blocking. If the application specifies blocking, the Gatekeeper API calls to setup the connection and
read a message that does not return until the action is complete.
blocking. If the application specifies blocking, the Gatekeeper API calls to setup the connection and
read a message that does not return until the action is complete.
Return
The return for this function is an integer. If the client socket connection has been set up successfully or
is in progress, a connection handle is returned. This connection handle is the socket descriptor that the
application uses to wait on a connection completion or read socket event. If an error occurs while setting
up the client connection, the value -1 is returned. In this case, the error information is provided in the
STATUS_TYPE.
is in progress, a connection handle is returned. This connection handle is the socket descriptor that the
application uses to wait on a connection completion or read socket event. If an error occurs while setting
up the client connection, the value -1 is returned. In this case, the error information is provided in the
STATUS_TYPE.
GkapiClientConnected
This function must be called by the application to indicate that a select event for a connect complete has
occurred.
occurred.
Input
The input to this function is:
•
A pointer to the
structure.
•
A pointer to the STATUS_TYPE enumeration. Possible values for STATUS_TYPE are:
–
PROCESSING_SUCCESSFUL—Successful connection to the Gatekeeper.
–
TCP_CONNECT_ERROR—Error was encountered in connecting to the Gatekeeper.
•
An integer that indicates that a connect complete has occurred.
Return
The return for this function is an integer. If the socket connection has been set up successfully or is in
progress, a connection handle is returned. This connection handle is the socket descriptor that the
application uses to wait on a connection completion or read socket event. If an error occurs while setting
up the client connection, the value -1 is returned. In this case, the error information is provided in the
STATUS_TYPE.
progress, a connection handle is returned. This connection handle is the socket descriptor that the
application uses to wait on a connection completion or read socket event. If an error occurs while setting
up the client connection, the value -1 is returned. In this case, the error information is provided in the
STATUS_TYPE.