CMINIT — Initialize_Conversation


CMINIT (conversation_ID, sym_dest_name, return_code) [LOGGING log_byte]

Where

conversation_ID (character output) specifies the conversation identifier assigned to the conversation. CPI Communications supplies and maintains the conversation_ID. If the CMINIT statement is successful (return_code is set to CM_OK), the local program uses the identifier returned in this variable for the rest of the conversation.

sym_dest_name (character input) specifies the symbolic destination name. The symbolic destination name is provided by the program and points to an entry in the side information table.1 The appropriate entry in the side information is retrieved and used to initialize the conversation's characteristics (such as partner LU name, partner TP name, and mode name to be used for the session). Alternatively, a blank sym_dest_name (one composed of eight space characters) may be specified. When this is done, the program is responsible for setting up the appropriate destination information, using Set statements, before issuing the CMALLC statement for this conversation.

return_code (numeric output) specifies the result of the statement execution.

log_byte is a 1-byte string constant or a string expression that specifies a byte of user data to be associated with this CPI-C statement during logging. The log_byte remains active until another CPI-C statement is issued. Only the first character or first two hexadecimal digits of the string expression are used. The default log_byte is X'00'.

Function

 

A program uses the CMINIT statement to simulate the CPI-C CMINIT call, which is used to initialize values for various conversation characteristics before the conversation is allocated (by a CMALLC statement). The remote partner program uses the CMACCP statement to initialize values for the conversation characteristics on its end of the conversation.

A program can override the values that are initialized by this statement using the appropriate Set statements, such as CMSSL to set the synchronization level. Once the value is changed, it remains changed until the end of the conversation or until changed again by a Set statement.

For more information on CMINIT and its parameters, refer to the Initialize_Conversation (CMINIT) call description in the “Call Reference” chapter of Systems Application Architecture Common Programming Interface Communications Reference.

1 You can find a discussion of the side information table in the "Simulating CPI-C Transaction Programs" chapter of Creating WSim Scripts. Further, you can find descriptions of the SIDEINFO operand of the APPCLU statement, and of the SIDEENT, SIDEINFO, and SIDEEND statements that make up the SIDEINFO group, in WSim language statements.