LU 6.2 API Application Programmer's Reference Guide (30294-90008)

52 Chapter4
Conversation States
Receive State
Receive State
In Receive state, a local TP can receive data and control information
from a remote TP. A local TP can enter Receive state from Send state by
calling either MCPrepToRcv or MCRcvAndWait. Both of these intrinsics
cause the local side of the conversation to change from Send state to
Receive state and the remote side to change from Receive state to Send
state.
Since the TP in Send state controls the conversation, a TP in Receive
state must wait to be placed in Send state by the controlling TP. A local
TP in Receive state can request to enter Send state by calling the
MCReqToSend intrinsic. The remote TP in Send state receives the
request, enters Receive state, and places the local TP in Send state.
NOTE
If a TP in Receive state detects an error, it can enter Send state directly
by calling MCSendError.
Table 4-4 lists the intrinsics that can be called from Receive state. It
also indicates what state the TP is in after each intrinsic executes
successfully. MCRcvAndWait and MCRcvNoWait can place the local side of
the conversation in several different states, depending on the type of
information received from the remote TP.
From Receive state, the MCDeallocate intrinsic can be called only with
the
DeallocateType
parameter set to 2 (ABEND). See the description
of MCDeallocate in Chapter 5 , “Intrinsic Descriptions,” for more
information.