Sun Adapter for IMS API

com.stc.eways.ims
Class IMSClientETDAdapter

java.lang.Object
  extended by com.stc.eways.ims.IMSClientETDAdapter
All Implemented Interfaces:
IMSClientETD

public class IMSClientETDAdapter
extends java.lang.Object
implements IMSClientETD


Field Summary
static int CONNECTION_MODE_AUTOMATIC
           
static int CONNECTION_MODE_MANUAL
           
 
Constructor Summary
IMSClientETDAdapter(com.stc.connector.appconn.common.ApplicationConnectionFactory appConnFactory, int connectionMode)
          Default constructor for IMSClientETDAdapter
 
Method Summary
 void connect()
          Connect to server.
 void disconnect()
          Disconnect from server.
 char getBandrs()
          Call this in your collaboration to get the bandrs attribute.
 java.lang.String getDatastoreID()
          Call this in your collaboration to get the datastoreID attribute.
 java.lang.String getLtermName()
          Call this in your collaboration to get the LtermName attribute.
 java.lang.String getMessage()
          Call this in your collaboration to get the message attribute.
 java.lang.String getPassword()
          Call this in your collaboration to get the Password attribute.
 java.lang.String getPort()
          Call this in your collaboration to get the port attribute.
 java.lang.String getRacfGroupName()
          Call this in your collaboration to get the RacfGroupName attribute.
 java.lang.String getRacfUserID()
          Call this in your collaboration to get the RacfUserID attribute.
 java.lang.String getReasonErrMsg()
          Call this in your collaboration to get the IMS Connect reason code error message
 java.lang.String getReply()
          Call this in your collaboration to get the reply from the server.
 byte[] getReplyBytes(int segNum)
          Call this in your collaboration to get the reply from the server as bytes.
 java.lang.String getReturnErrMsg()
          Call this in your collaboration to get the IMS Connect return code error message
 int getSegmentCount()
          Call this in your collaboration to return the number of segments in the reply message.
 java.lang.String getServer()
          Call this in your collaboration to get the server attribute.
 java.lang.String getTranCode()
          Call this in your collaboration to get the trans code attribute.
 java.lang.String getTranCodeSrc()
          Call this in your collaboration to get the trans code source attribute.
 void IMSRequest()
          Call this in your collaboration to send the current value of Message to the server.
 void IMSRequest(java.lang.String inputMessage)
          Call this in your collaboration to send a message to the server.
 void IMSRequestWithMultiSegs(java.lang.String[] inputMessages)
          Call this in your collaboration to send multi-segmented messages to the server.
 void internalDisconnect()
           
 boolean isConnected()
          Check to see if connected to server.
 boolean reset()
          reset
 void setBandrs(char msg)
          Call this in your collaboration to set the bandrs attribute.
 void setDatastoreID(java.lang.String msg)
          Call this in your collaboration to set the datastoreID attribute.
 void setLtermName(java.lang.String msg)
          Call this in your collaboration to set the LtermName attribute.
 void setMessage(java.lang.String msg)
          Call this in your collaboration to set the message attribute.
 void setPassword(java.lang.String msg)
          Call this in your collaboration to set the Password attribute.
 void setPort(java.lang.String msg)
          Call this in your collaboration to set the port attribute.
 void setRacfGroupName(java.lang.String msg)
          Call this in your collaboration to set the RacfGroupName attribute.
 void setRacfUserID(java.lang.String msg)
          Call this in your collaboration to set the RacfUserID attribute.
 void setServer(java.lang.String msg)
          Call this in your collaboration to set the server attribute.
 void setTranCode(java.lang.String msg)
          Call this in your collaboration to set the trans code attribute.
 void setTranCodeSrc(java.lang.String msg)
          Call this in your collaboration to set the trans code source attribute.
 void terminate()
          terminate Closes external connection.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CONNECTION_MODE_AUTOMATIC

public static final int CONNECTION_MODE_AUTOMATIC
See Also:
Constant Field Values

CONNECTION_MODE_MANUAL

public static final int CONNECTION_MODE_MANUAL
See Also:
Constant Field Values
Constructor Detail

IMSClientETDAdapter

public IMSClientETDAdapter(com.stc.connector.appconn.common.ApplicationConnectionFactory appConnFactory,
                           int connectionMode)
Default constructor for IMSClientETDAdapter

Parameters:
appConnFactory - The ApplicationConnectionFactory.
connectionMode - The connection mode
Method Detail

setServer

public void setServer(java.lang.String msg)
Call this in your collaboration to set the server attribute.

Specified by:
setServer in interface IMSClientETD
Parameters:
server - - server host

getServer

public java.lang.String getServer()
Call this in your collaboration to get the server attribute.

Specified by:
getServer in interface IMSClientETD
Returns:
server host

setPort

public void setPort(java.lang.String msg)
Call this in your collaboration to set the port attribute.

Specified by:
setPort in interface IMSClientETD
Parameters:
server - port

getPort

public java.lang.String getPort()
Call this in your collaboration to get the port attribute.

Specified by:
getPort in interface IMSClientETD
Returns:
server port

setMessage

public void setMessage(java.lang.String msg)
Call this in your collaboration to set the message attribute.

Specified by:
setMessage in interface IMSClientETD
Parameters:
message -

getMessage

public java.lang.String getMessage()
Call this in your collaboration to get the message attribute.

Specified by:
getMessage in interface IMSClientETD
Returns:
message

setBandrs

public void setBandrs(char msg)
Call this in your collaboration to set the bandrs attribute. blank = NoAck A = ACK, N = NACK, D = Deallocate, R = Resume, S = SendOnly

Specified by:
setBandrs in interface IMSClientETD
Parameters:
bandrs -

getBandrs

public char getBandrs()
Call this in your collaboration to get the bandrs attribute.

Specified by:
getBandrs in interface IMSClientETD
Returns:
bandrs

setTranCode

public void setTranCode(java.lang.String msg)
Call this in your collaboration to set the trans code attribute.

Specified by:
setTranCode in interface IMSClientETD
Parameters:
TranCode -

getTranCode

public java.lang.String getTranCode()
Call this in your collaboration to get the trans code attribute.

Specified by:
getTranCode in interface IMSClientETD
Returns:
TranCode

setTranCodeSrc

public void setTranCodeSrc(java.lang.String msg)
Call this in your collaboration to set the trans code source attribute. If TranCodeSrc is set to "MESSAGE", the transaction ID will be picked up from the first eight bytes of the Message. Otherwise, it will be picked up from the config file.

Specified by:
setTranCodeSrc in interface IMSClientETD
Parameters:
TranCodeSrc -

getTranCodeSrc

public java.lang.String getTranCodeSrc()
Call this in your collaboration to get the trans code source attribute.

Specified by:
getTranCodeSrc in interface IMSClientETD
Returns:
TranCodeSrc

setDatastoreID

public void setDatastoreID(java.lang.String msg)
Call this in your collaboration to set the datastoreID attribute.

Specified by:
setDatastoreID in interface IMSClientETD
Parameters:
datastoreID -

getDatastoreID

public java.lang.String getDatastoreID()
Call this in your collaboration to get the datastoreID attribute.

Specified by:
getDatastoreID in interface IMSClientETD
Returns:
datastoreID

setLtermName

public void setLtermName(java.lang.String msg)
Call this in your collaboration to set the LtermName attribute.

Specified by:
setLtermName in interface IMSClientETD
Parameters:
LtermName -

getLtermName

public java.lang.String getLtermName()
Call this in your collaboration to get the LtermName attribute.

Specified by:
getLtermName in interface IMSClientETD
Returns:
LtermName

setRacfUserID

public void setRacfUserID(java.lang.String msg)
Call this in your collaboration to set the RacfUserID attribute.

Specified by:
setRacfUserID in interface IMSClientETD
Parameters:
RacfUserID -

getRacfUserID

public java.lang.String getRacfUserID()
Call this in your collaboration to get the RacfUserID attribute.

Specified by:
getRacfUserID in interface IMSClientETD
Returns:
RacfUserID

setRacfGroupName

public void setRacfGroupName(java.lang.String msg)
Call this in your collaboration to set the RacfGroupName attribute.

Specified by:
setRacfGroupName in interface IMSClientETD
Parameters:
RacfGroupName -

getRacfGroupName

public java.lang.String getRacfGroupName()
Call this in your collaboration to get the RacfGroupName attribute.

Specified by:
getRacfGroupName in interface IMSClientETD
Returns:
RacfGroupName

setPassword

public void setPassword(java.lang.String msg)
Call this in your collaboration to set the Password attribute.

Specified by:
setPassword in interface IMSClientETD
Parameters:
Password -

getPassword

public java.lang.String getPassword()
Call this in your collaboration to get the Password attribute.

Specified by:
getPassword in interface IMSClientETD
Returns:
Password

reset

public boolean reset()
reset

Specified by:
reset in interface IMSClientETD
Returns:
false if the IMSClientETD doesn't have a meaningful implementation of reset(); so do a new of the IMSClientETD instead. Otherwise, return true if the reset will clear the data content of the IMSClient.

terminate

public void terminate()
               throws IMSClientException
terminate Closes external connection.

Throws:
IMSClientException

connect

public void connect()
             throws IMSClientException
Connect to server.

Specified by:
connect in interface IMSClientETD
Throws:
IMSClientException - upon an external connection problem

disconnect

public void disconnect()
                throws IMSClientException
Disconnect from server.

Specified by:
disconnect in interface IMSClientETD
Throws:
IMSClientException - upon an external connection problem

isConnected

public boolean isConnected()
                    throws IMSClientException
Check to see if connected to server.

Specified by:
isConnected in interface IMSClientETD
Throws:
IMSClientException - upon an external connection problem

IMSRequest

public void IMSRequest(java.lang.String inputMessage)
                throws IMSClientException
Call this in your collaboration to send a message to the server.

Specified by:
IMSRequest in interface IMSClientETD
Parameters:
inputMessage - String
Throws:
IMSClientException

IMSRequestWithMultiSegs

public void IMSRequestWithMultiSegs(java.lang.String[] inputMessages)
                             throws IMSClientException
Call this in your collaboration to send multi-segmented messages to the server.

Specified by:
IMSRequestWithMultiSegs in interface IMSClientETD
Parameters:
inputMessages - String[]
Throws:
IMSClientException

IMSRequest

public void IMSRequest()
                throws IMSClientException
Call this in your collaboration to send the current value of Message to the server.

Specified by:
IMSRequest in interface IMSClientETD
Throws:
IMSClientException

getReply

public java.lang.String getReply()
                          throws IMSClientException
Call this in your collaboration to get the reply from the server.

Specified by:
getReply in interface IMSClientETD
Returns:
String
Throws:
IMSClientException

getSegmentCount

public int getSegmentCount()
                    throws IMSClientException
Call this in your collaboration to return the number of segments in the reply message.

Specified by:
getSegmentCount in interface IMSClientETD
Returns:
int
Throws:
IMSClientException

getReplyBytes

public byte[] getReplyBytes(int segNum)
                     throws IMSClientException
Call this in your collaboration to get the reply from the server as bytes.

Specified by:
getReplyBytes in interface IMSClientETD
Parameters:
segNum - int
Returns:
byte[]
Throws:
IMSClientException

getReturnErrMsg

public java.lang.String getReturnErrMsg()
Call this in your collaboration to get the IMS Connect return code error message

Specified by:
getReturnErrMsg in interface IMSClientETD
Returns:
String

getReasonErrMsg

public java.lang.String getReasonErrMsg()
Call this in your collaboration to get the IMS Connect reason code error message

Specified by:
getReasonErrMsg in interface IMSClientETD
Returns:
String

internalDisconnect

public void internalDisconnect()
                        throws com.stc.connector.appconn.common.ApplicationConnectionException
Throws:
com.stc.connector.appconn.common.ApplicationConnectionException

Sun Adapter for IMS API