public class Conversation extends API
This class implements the interface that is common to both ends of an APPC conversation.
com.ibm.cics.server.API
for general restrictions on using the JCICS API.
Modifier and Type | Method and Description |
---|---|
void |
converse(DataHolder data)
DTC converse
|
void |
converse(DataHolder data,
int maxLength,
boolean retainExcess)
DTC Converse
|
void |
flush()
flush the connection
|
void |
free()
Free the connection
|
byte[] |
getConvId()
Get the conversation identifier for a conversation.
|
boolean |
getDataComplete()
Has all data been received?
|
int |
getErrorCode()
What was the last error code on this conversation?
|
boolean |
getErrorOccurred()
Has there been an error on this conversation?
|
boolean |
getNoData()
Have we received a message without data?
|
boolean |
getSignalReceived()
Have we received a SIGNAL?
|
ConversationState |
getState() |
SyncLevel |
getSyncLevel() |
void |
issueAbend() |
void |
issueConfirmation() |
void |
issueError() |
void |
issuePrepare() |
void |
issueSignal() |
void |
receive(DataHolder data)
DTC converse
|
void |
receive(DataHolder data,
int maxLength,
boolean retainExcess)
DTC converse
|
void |
send(byte[] data)
Send data.
|
void |
send(byte[] data,
ConversationSendOptions options) |
void |
send(ConversationSendOptions options) |
public void converse(DataHolder data) throws EndOfChainIndicatorException, InvalidRequestException, LengthErrorException, NotAllocatedException, InboundSignalException, TerminalException
data
- the data to sendEndOfChainIndicatorException
- EOC occurred.InvalidRequestException
- INVREQ occurred.LengthErrorException
- LENGERR occurred.NotAllocatedException
- NOTALLOC occurred.InboundSignalException
- SIGNAL occurred.TerminalException
- TERMERR occurred.public void converse(DataHolder data, int maxLength, boolean retainExcess) throws EndOfChainIndicatorException, InvalidRequestException, LengthErrorException, NotAllocatedException, InboundSignalException, TerminalException
data
- the data to sendmaxLength
- the maximum length of the dataretainExcess
- should excess data be retained?EndOfChainIndicatorException
- EOC occurred.InvalidRequestException
- INVREQ occurred.LengthErrorException
- LENGERR occurred.NotAllocatedException
- NOTALLOC occurred.InboundSignalException
- SIGNAL occurred.TerminalException
- TERMERR occurred.public void flush() throws InvalidRequestException, NotAllocatedException
InvalidRequestException
- INVREQNotAllocatedException
- NOTALLOCpublic void free() throws InvalidRequestException, NotAllocatedException, NotAuthorisedException, InvalidSystemIdException
InvalidRequestException
- INVREQNotAllocatedException
- NOTALLOCNotAuthorisedException
- NOTAUTHInvalidSystemIdException
- SYSIDERRpublic byte[] getConvId()
public boolean getDataComplete()
public int getErrorCode()
public boolean getErrorOccurred()
public boolean getNoData()
public boolean getSignalReceived()
public ConversationState getState()
public SyncLevel getSyncLevel()
public void issueAbend() throws InvalidRequestException, NotAllocatedException, TerminalException
InvalidRequestException
- INVREQNotAllocatedException
- NOTALLOCTerminalException
- TERMERRpublic void issueConfirmation() throws InvalidRequestException, NotAllocatedException, TerminalException
InvalidRequestException
- INVREQNotAllocatedException
- NOTALLOCTerminalException
- TERMERRpublic void issueError() throws InvalidRequestException, NotAllocatedException, TerminalException
InvalidRequestException
- INVREQNotAllocatedException
- NOTALLOCTerminalException
- TERMERRpublic void issuePrepare() throws InvalidRequestException, NotAllocatedException, TerminalException
InvalidRequestException
- INVREQNotAllocatedException
- NOTALLOCTerminalException
- TERMERRpublic void issueSignal() throws InvalidRequestException, NotAllocatedException, TerminalException
InvalidRequestException
- INVREQNotAllocatedException
- NOTALLOCTerminalException
- TERMERRpublic void receive(DataHolder data) throws EndOfChainIndicatorException, InvalidRequestException, LengthErrorException, NotAllocatedException, InboundSignalException, TerminalException
data
- the data received on the connectionEndOfChainIndicatorException
- EOC occurred.InvalidRequestException
- INVREQ occurred.LengthErrorException
- LENGERR occurred.NotAllocatedException
- NOTALLOC occurred.InboundSignalException
- SIGNAL occurred.TerminalException
- TERMERR occurred.public void receive(DataHolder data, int maxLength, boolean retainExcess) throws EndOfChainIndicatorException, InvalidRequestException, LengthErrorException, NotAllocatedException, InboundSignalException, TerminalException
data
- the data received on the connectionmaxLength
- the maximum length to receiveretainExcess
- should excess data be retained?EndOfChainIndicatorException
- EOC occurred.InvalidRequestException
- INVREQ occurred.LengthErrorException
- LENGERR occurred.NotAllocatedException
- NOTALLOC occurred.InboundSignalException
- SIGNAL occurred.TerminalException
- TERMERR occurred.public void send(byte[] data) throws InvalidRequestException, LengthErrorException, NotAllocatedException, InboundSignalException, TerminalException
If you want to achieve the effect of specifying LENGTH(0) in the EXEC CICS command interface, you must pass in an array of length 0.
If you want to achieve the effect of not sending any data, pass in null as the data.
data
- the data to sendInvalidRequestException
- INVREQLengthErrorException
- LENGERRNotAllocatedException
- NOTALLOCInboundSignalException
- SIGNALTerminalException
- TERMERRpublic void send(byte[] data, ConversationSendOptions options) throws InvalidRequestException, LengthErrorException, NotAllocatedException, InboundSignalException, TerminalException
data
- the data to sendoptions
- the options to setInvalidRequestException
- INVREQLengthErrorException
- LENGERRNotAllocatedException
- NOTALLOCInboundSignalException
- SIGNALTerminalException
- TERMERRpublic void send(ConversationSendOptions options) throws InvalidRequestException, LengthErrorException, NotAllocatedException, InboundSignalException, TerminalException
options
- the options to setInvalidRequestException
- INVREQLengthErrorException
- LENGERRNotAllocatedException
- NOTALLOCInboundSignalException
- SIGNALTerminalException
- TERMERR