CICS® Transaction Gateway Programming Reference V3.1

com.ibm.ctg.client
Class SslJavaGateway

com.ibm.ctg.client.SslJavaGateway

public class SslJavaGateway
implements java.lang.Runnable

This class manages the connection between a program and a CICS Gateway for Java. You will need a SslJavaGateway object for each Gateway that you wish to talk to. Once a connection has been established, you send GatewayRequest objects (or sub-classes of) to the Gateway via the flow method.

A SslJavaGateway object has a second thread which is used to listen for in-bound replies from the Gateway.


Method Summary
(package private)  void close()
          Closes the connection to the CICS Gateway for Java.
(package private)  int flow(GatewayRequest gatRequest)
          Flows the specified GatewayRequest to the CICS Gateway for Java and then waits for the reply.
static java.lang.String getKeyRing()
          Returns the KeyRing class used for the client connection.
(package private)  void open()
          Opens a SslJavaGateway, connecting it to the CICS Gateway for Java at the specified IP address and port.
static void setKeyRing(java.lang.String strSetKeyRing, java.lang.String strSetKeyRingPW)
          This method sets the SSL KeyRing class to be used for the client connection, and also the PASSWORD for the encrypted keyring.
 

Method Detail

open

void open()
    throws java.io.IOException
Opens a SslJavaGateway, connecting it to the CICS Gateway for Java at the specified IP address and port. Creating a new SslJavaGateway will cause the creation of a background listener thread associated with that SslJavaGateway object.
Throws:
java.io.IOException - If an error occurs when creating the SslJavaGateway

flow

int flow(GatewayRequest gatRequest)
   throws java.io.IOException
Flows the specified GatewayRequest to the CICS Gateway for Java and then waits for the reply. The reply is returned in the original request object.
Parameters:
gatRequest - GatewayRequest object containing the request
Returns:
Return code from this flow operation
Throws:
java.io.IOException - If a network I/O error occurs during the operation

close

void close()
     throws java.io.IOException
Closes the connection to the CICS Gateway for Java. If there were any other threads using this SslJavaGateway who were in the middle of a flow operation, they will return with a error.
Throws:
java.io.IOException - If a network I/O error occurs during the operation

setKeyRing

public static void setKeyRing(java.lang.String strSetKeyRing,
                              java.lang.String strSetKeyRingPW)
This method sets the SSL KeyRing class to be used for the client connection, and also the PASSWORD for the encrypted keyring.
Parameters:
strSetKeyRing - contains the full classname of the KeyRing class
strSetKeyRingPW - contains the PASSWORD for the encrypted KeyRing class

getKeyRing

public static java.lang.String getKeyRing()
Returns the KeyRing class used for the client connection.
Returns:
string containing the full KeyRing classname

© Copyright IBM Corp. 1994, 1999