IBM WebSphere Multichannel Bank Transformation Toolkit Javadoc

com.ibm.btt.clientserver
Interface CSClientService

All Superinterfaces:
Notifier
All Known Implementing Classes:
CSClient

public interface CSClientService
extends Notifier

The CSClientService interface provides the C/S service interface on the client side.


Field Summary
static java.lang.String CS_REPLY_EVENT
           
static java.lang.String CS_REQUEST_ID
           
static java.lang.String CS_SESSION_STATUS
           
static java.lang.String CS_STATUS_CHANGED_EVENT
           
static int DOWN
           
static java.lang.String ENABLESSL
           
static int NOT_ESTABLISHED
           
static int OK
           
static int RESET
           
static java.lang.String SSLENABLER
           
 
Method Summary
 void addCSConnectionCookies(java.lang.String clientCookieStr)
          Adds a client cookie for the connection.
 void addCSConnectionCookies(java.util.Vector clientCookiesVector)
          Adds client cookies for the connection.
 void addCSNotificationListener(CSNotificationListener newListener)
          Registers the notification of events.
 void addCSReplyListener(CSReplyListener newListener)
          Registers the notification of a request reply
 void addCSSessionStatusChangedListener(CSSessionStatusChangedListener newListener)
          Registers the notification of client/server status changes
 void closeSession()
          Closes the session.
 void establishSession()
          Establishes a session with the server.
 void establishSession(boolean newSession)
          Establishes a session with the server Should the request attempt to create a session or use an existing session
 long getDefaultOperationTimeout()
          Returns the timeout used in the methods sendAndWait(ClientOperation), receive(ClientOperation, Integer), receive (Context, Integer).
 int getEventsPort()
          Gets the events port.
 boolean getKeepAliveConnection()
          Returns false if the connection with the server is used only for one request.
 boolean getPermanentConnectionForEvents()
          Gets the permanentConnectionForEvents attribute
 java.lang.String getProxyCredentials()
          Returns the authentification proxy info.
 java.lang.String getProxyHost()
          Returns the name of the proxy address (HTTP address).
 int getProxyPort()
          Gets the proxy port.
 int getReconnectionAttempts()
          Returns the number of attempts to reestablish the connection.
 java.lang.String getServerCredentials()
          Returns the authentification server info.
 java.lang.String getServerName()
          Returns the name of the server address (HTTP address).
 java.net.ServerSocket getServerSocket()
          Gets the server socket.
 java.lang.String getServerTID()
          Gets the server terminal ID.
 java.lang.String getSessionId()
          Gets the session ID assigned by the server.
 int getSessionStatus()
          Gets the session status.
 SSLEnabler getSSLEnabler()
          Returns the sslEnabler.
 long getTimeBetweenReconnectionAttempts()
          Gets the time between reconnection attempts when the session is down.
 boolean getUsedForSrvToClEventsNotif()
          Gets true if the CSClient is used on the server for client event notification.
 boolean getUseProxy()
          Returns true if the CSClientService establish a connection through a proxy.
 boolean isEnableSSL()
          Returns the enableSSL.
 void receive(ClientOperation aClientOperation, java.lang.Integer requestId)
          Used together with the asynchronous send(...) method.
 void receive(ClientOperation aClientOperation, java.lang.Integer requestId, long timeout)
          Used together with the asynchronous send(...) method.
 void receive(Context aContext, java.lang.Integer requestId)
          Used together with the asynchronous send(...) method.
 void receive(Context aContext, java.lang.Integer requestId, long timeout)
          Used together with the asynchronous send(...) method.
 void removeCSNotificationListener(CSNotificationListener newListener)
          Removes the specified CSNotificationListener so that it no longer receives CSNotificationEvents from this interfice.
 void removeCSReplyListener(CSReplyListener newListener)
          Removes the specified CSReplyListener so that it no longer receives CSReplyEvents from this interfice.
 void removeCSSessionStatusChangedListener(CSSessionStatusChangedListener newListener)
          Removes the specified CSSessionStatusChangedListener so that it no longer receives CSSessionStatusChangedEvents from this interfice.
 java.lang.Integer send(ClientOperation aClientOperation)
          Instantiates the remote execution of the operation on the server side.
 void sendAndWait(ClientOperation aClientOperation)
          Initiates the remote execution of the operation on the server side and waits.
 void sendAndWait(ClientOperation aClientOperation, long timeout)
          Initiates the remote execution of the operation on the server side and waits for a timeout.
 void sendEvent(java.util.EventObject myEvent)
          Sends an event to the server.
 void setDefaultOperationTimeout(long aTimeout)
          Sets the defaultOperationTimeout property (long) value.
 void setEnableSSL(boolean enableSSL)
          Sets the enableSSL.
 void setEventsPort(int aPort)
          Sets the events port.
 void setKeepAliveConnection(boolean value)
          Sets the option to use the connection with the server for more than one request.
 void setPermanentConnectionForEvents(boolean permanent)
          Sets the permanentConnectionForEvents attribute.
 void setProxyCredentials(java.lang.String aProxyCredentials)
          Sets the authentification proxy info.
 void setProxyHost(java.lang.String value)
          Sets set the name of the proxy address (HTTP address)
 void setProxyPort(int value)
          Sets the proxy port.
 void setReconnectionAttempts(int value)
          Sets the number of attempts to reestablish the connection.
 void setServerCredentials(java.lang.String aServerCredentials)
          Sets the authentification server info.
 void setServerName(java.lang.String serverName)
          Sets the name of the server address (HTTP address).
 void setServerSocket(java.net.ServerSocket aSocket)
          Sets the server socket.
 void setSSLEnabler(SSLEnabler sslEnabler)
          Sets the sslEnabler.
 void setTimeBetweenReconnectionAttempts(long value)
          Sets the time between reconnection attempts when the session is down.
 void setUsedForSrvToClEventNotif(boolean used)
           
 void setUseProxy(boolean value)
          Sets the option to establish a connection with the server through a proxy.
 
Methods inherited from interface com.ibm.btt.event.Notifier
getName, setName, signalEvent, signalEvent, terminate
 

Field Detail

RESET

static final int RESET
See Also:
Constant Field Values

OK

static final int OK
See Also:
Constant Field Values

DOWN

static final int DOWN
See Also:
Constant Field Values

NOT_ESTABLISHED

static final int NOT_ESTABLISHED
See Also:
Constant Field Values

CS_STATUS_CHANGED_EVENT

static final java.lang.String CS_STATUS_CHANGED_EVENT
See Also:
Constant Field Values

CS_SESSION_STATUS

static final java.lang.String CS_SESSION_STATUS
See Also:
Constant Field Values

CS_REPLY_EVENT

static final java.lang.String CS_REPLY_EVENT
See Also:
Constant Field Values

CS_REQUEST_ID

static final java.lang.String CS_REQUEST_ID
See Also:
Constant Field Values

ENABLESSL

static final java.lang.String ENABLESSL
See Also:
Constant Field Values

SSLENABLER

static final java.lang.String SSLENABLER
See Also:
Constant Field Values
Method Detail

addCSConnectionCookies

void addCSConnectionCookies(java.util.Vector clientCookiesVector)
Adds client cookies for the connection.

Parameters:
clientCookiesVector - java.util.Vector

addCSConnectionCookies

void addCSConnectionCookies(java.lang.String clientCookieStr)
Adds a client cookie for the connection.

Parameters:
clientCookieStr - java.lang.String

addCSNotificationListener

void addCSNotificationListener(CSNotificationListener newListener)
Registers the notification of events.

Parameters:
newListener - com.ibm.btt.clientserver.CSNotificationListener

addCSReplyListener

void addCSReplyListener(CSReplyListener newListener)
Registers the notification of a request reply

Parameters:
newListener - com.ibm.btt.clientserver.CSReplyListener

addCSSessionStatusChangedListener

void addCSSessionStatusChangedListener(CSSessionStatusChangedListener newListener)
Registers the notification of client/server status changes

Parameters:
newListener - com.ibm.btt.clientserver.CSSessionStatusChangedListener

closeSession

void closeSession()
                  throws DSECSInvalidRequestException
Closes the session.

Throws:
DSECSInvalidRequestException

establishSession

void establishSession()
                      throws DSECSInvalidRequestException,
                             DSECSSessionNotEstablishedException
Establishes a session with the server.

Throws:
DSECSInvalidRequestException
DSECSSessionNotEstablishedException

establishSession

void establishSession(boolean newSession)
                      throws DSECSInvalidRequestException,
                             DSECSSessionNotEstablishedException
Establishes a session with the server Should the request attempt to create a session or use an existing session

Parameters:
boolean - newSession
Throws:
DSECSInvalidRequestException
DSECSSessionNotEstablishedException

getDefaultOperationTimeout

long getDefaultOperationTimeout()
Returns the timeout used in the methods sendAndWait(ClientOperation), receive(ClientOperation, Integer), receive (Context, Integer).

Returns:
long

getKeepAliveConnection

boolean getKeepAliveConnection()
Returns false if the connection with the server is used only for one request.

Returns:
boolean

getProxyCredentials

java.lang.String getProxyCredentials()
Returns the authentification proxy info.

Returns:
java.lang.String

getProxyHost

java.lang.String getProxyHost()
Returns the name of the proxy address (HTTP address).

Returns:
java.lang.String

getProxyPort

int getProxyPort()
Gets the proxy port.

Returns:
int

getReconnectionAttempts

int getReconnectionAttempts()
Returns the number of attempts to reestablish the connection.

Returns:
java.lang.String

getServerCredentials

java.lang.String getServerCredentials()
Returns the authentification server info.

Returns:
java.lang.String

getServerName

java.lang.String getServerName()
Returns the name of the server address (HTTP address).

Returns:
java.lang.String

getServerTID

java.lang.String getServerTID()
Gets the server terminal ID.

Returns:
java.lang.String

getSessionId

java.lang.String getSessionId()
Gets the session ID assigned by the server.

Returns:
java.lang.String

getSessionStatus

int getSessionStatus()
Gets the session status. The values for session status are: RESET= 0, OK= 1, DOWN= 2, NOT_ESTABLISHED= 3.

Returns:
int

getTimeBetweenReconnectionAttempts

long getTimeBetweenReconnectionAttempts()
Gets the time between reconnection attempts when the session is down.

Returns:
long

getUsedForSrvToClEventsNotif

boolean getUsedForSrvToClEventsNotif()
Gets true if the CSClient is used on the server for client event notification.


getUseProxy

boolean getUseProxy()
Returns true if the CSClientService establish a connection through a proxy.

Returns:
boolean

receive

void receive(ClientOperation aClientOperation,
             java.lang.Integer requestId)
             throws DSECSInvalidRequestException,
                    DSECSTimeoutException,
                    DSECSRemoteOperationException
Used together with the asynchronous send(...) method. The RequestId identifies which request owns the answer. The timeout of this method must be specified in the defaultOperationTimeout property

Parameters:
aClientOperation - ClientOperation
requesId - java.lang.Integer
Throws:
DSECSInvalidRequestException
DSECSTimeoutException
DSECSRemoteOperationException

receive

void receive(ClientOperation aClientOperation,
             java.lang.Integer requestId,
             long timeout)
             throws DSECSInvalidRequestException,
                    DSECSTimeoutException,
                    DSECSRemoteOperationException
Used together with the asynchronous send(...) method. The RequestId identifies which request owns the answer. The Timeout must be specified in milliseconds. A value equal to zero means to wait forever.

Parameters:
aClientOperation - ClientOperation
requesId - java.lang.Integer
timeout - long
Throws:
DSECSInvalidRequestException
DSECSTimeoutException
DSECSRemoteOperationException

receive

void receive(Context aContext,
             java.lang.Integer requestId)
             throws DSECSInvalidRequestException,
                    DSECSTimeoutException,
                    DSECSRemoteOperationException
Used together with the asynchronous send(...) method. The RequestId identifies which request owns the answer. The timeout of this method must be specified in the defaultOperationTimeout property.

Parameters:
aContext - Context
requesId - java.lang.Integer
Throws:
DSECSInvalidRequestException
DSECSTimeoutException
DSECSRemoteOperationException

receive

void receive(Context aContext,
             java.lang.Integer requestId,
             long timeout)
             throws DSECSInvalidRequestException,
                    DSECSTimeoutException,
                    DSECSRemoteOperationException
Used together with the asynchronous send(...) method. The RequestId identifies which request owns the answer. The Timeout must be specified in milliseconds. A value equal to zero means to wait forever.

Parameters:
aContext - Context
requesId - java.lang.Integer
timeout - long
Throws:
DSECSInvalidRequestException
DSECSTimeoutException
DSECSRemoteOperationException

removeCSNotificationListener

void removeCSNotificationListener(CSNotificationListener newListener)
Removes the specified CSNotificationListener so that it no longer receives CSNotificationEvents from this interfice.

Parameters:
newListener - com.ibm.btt.clientserver.CSNotificationListener

removeCSReplyListener

void removeCSReplyListener(CSReplyListener newListener)
Removes the specified CSReplyListener so that it no longer receives CSReplyEvents from this interfice.

Parameters:
newListener - com.ibm.btt.clientserver.CSReplyListener

removeCSSessionStatusChangedListener

void removeCSSessionStatusChangedListener(CSSessionStatusChangedListener newListener)
Removes the specified CSSessionStatusChangedListener so that it no longer receives CSSessionStatusChangedEvents from this interfice.

Parameters:
newListener - com.ibm.btt.clientserver.CSSessionStatusChangedListener

send

java.lang.Integer send(ClientOperation aClientOperation)
                       throws DSECSInvalidRequestException
Instantiates the remote execution of the operation on the server side. It is an asynchcronous method.

Parameters:
aClientOperation - ClientOperation
Returns:
Integer
Throws:
DSECSInvalidRequestException

sendAndWait

void sendAndWait(ClientOperation aClientOperation)
                 throws DSECSTimeoutException,
                        DSECSInvalidRequestException,
                        DSECSRemoteOperationException
Initiates the remote execution of the operation on the server side and waits. It is a synchronous method. The timeout of this method must be specified in the defaultOperationTimeout property

Parameters:
aClientOperation - ClientOperation
Throws:
DSECSTimeoutException
DSECSInvalidRequestException
DSECSRemoteOperationException

sendAndWait

void sendAndWait(ClientOperation aClientOperation,
                 long timeout)
                 throws DSECSTimeoutException,
                        DSECSInvalidRequestException,
                        DSECSRemoteOperationException
Initiates the remote execution of the operation on the server side and waits for a timeout. It is a synchronous method. The timeout must be specified in milliseconds. A value equal to zero means it will wait forever.

Parameters:
aClientOperation - ClientOperation
timeout - long
Throws:
DSECSTimeoutException
DSECSInvalidRequestException
DSECSRemoteOperationException

sendEvent

void sendEvent(java.util.EventObject myEvent)
               throws DSECSInvalidRequestException
Sends an event to the server.

Parameters:
evt - EventObject
Throws:
DSECSInvalidRequestException

setDefaultOperationTimeout

void setDefaultOperationTimeout(long aTimeout)
Sets the defaultOperationTimeout property (long) value. This timeout is used in the methods sendAndWait(ClientOperation), receive(ClientOperation, Integer), receive (Context, Integer).

Parameters:
aTimeout - long

setKeepAliveConnection

void setKeepAliveConnection(boolean value)
Sets the option to use the connection with the server for more than one request.

Parameters:
value - boolean

setProxyCredentials

void setProxyCredentials(java.lang.String aProxyCredentials)
Sets the authentification proxy info. The parameter aProxyCredentials must be in the next format: userId:password

Parameters:
aProxyCredentials - java.lang.String

setProxyHost

void setProxyHost(java.lang.String value)
Sets set the name of the proxy address (HTTP address)

Parameters:
value - java.lang.String

setProxyPort

void setProxyPort(int value)
Sets the proxy port.

Parameters:
value - int

setReconnectionAttempts

void setReconnectionAttempts(int value)
Sets the number of attempts to reestablish the connection.

Parameters:
value - int

setServerCredentials

void setServerCredentials(java.lang.String aServerCredentials)
Sets the authentification server info. The parameter aServerCredentials must be in the next format: userId:password

Parameters:
aServerCredentials - java.lang.String

setServerName

void setServerName(java.lang.String serverName)
Sets the name of the server address (HTTP address).

Parameters:
serverName - java.lang.String

setTimeBetweenReconnectionAttempts

void setTimeBetweenReconnectionAttempts(long value)
Sets the time between reconnection attempts when the session is down.

Parameters:
value - long

setUsedForSrvToClEventNotif

void setUsedForSrvToClEventNotif(boolean used)
Parameters:
used - boolean

setUseProxy

void setUseProxy(boolean value)
Sets the option to establish a connection with the server through a proxy.

Parameters:
used - boolean

getEventsPort

int getEventsPort()
Gets the events port.

Returns:
int

getServerSocket

java.net.ServerSocket getServerSocket()
Gets the server socket.

Returns:
java.net.ServerSocket

getPermanentConnectionForEvents

boolean getPermanentConnectionForEvents()
Gets the permanentConnectionForEvents attribute

Returns:
boolean

setEventsPort

void setEventsPort(int aPort)
Sets the events port.

Parameters:
aPort - int

setServerSocket

void setServerSocket(java.net.ServerSocket aSocket)
Sets the server socket.

Parameters:
aSocket - java.net.ServerSocket

setPermanentConnectionForEvents

void setPermanentConnectionForEvents(boolean permanent)
Sets the permanentConnectionForEvents attribute.

Parameters:
boolean - permanent

isEnableSSL

boolean isEnableSSL()
Returns the enableSSL.

Returns:
boolean

setEnableSSL

void setEnableSSL(boolean enableSSL)
Sets the enableSSL.

Parameters:
enableSSL - - The enableSSL to set

getSSLEnabler

SSLEnabler getSSLEnabler()
Returns the sslEnabler.

Returns:
SSLEnabler

setSSLEnabler

void setSSLEnabler(SSLEnabler sslEnabler)
Sets the sslEnabler.

Parameters:
sslEnabler - - The sslEnabler to set

IBM WebSphere Multichannel Bank Transformation Toolkit Javadoc

(c) Copyright IBM Corporation 1998, 2009