HPlogo LU 6.2 API Application Programmer's Reference Manual: HP 3000 MPE/iX Computer Systems > Chapter 5  Intrinsic Descriptions

MCPostOnRcpt

» 

Technical documentation

Complete book in PDF
» Feedback

 » Table of Contents

 » Glossary

 » Index

Allows the LU to check the contents of the receive buffer for the specified conversation.

Syntax

			                I16V       I16V   CA    I32
									MCPostOnRcpt(ResourceID, Length, Data, Status);

Parameters

ResourceID

Required; 16-bit signed integer by value; input. This is the unique resource ID number assigned to this conversation when it was allocated. See MCAllocate or MCGetAllocate, in this chapter, for more information.

Length

Required; 16-bit signed integer by value; input. This parameter specifies the minimum amount of data (in bytes) that must be received in the receive buffer before the TP is to be notified. If the logical record length is less than the number specified in this parameter, the TP will be notified when a complete logical record is received. A value of 0 or 1 in this parameter indicates that the TP is to be notified when any amount of data is received. The value of Length may not exceed 4092 bytes.

Data

Required; character array; input. This is the character array into which data will be received after it arrives in the receive buffer. Its length must be greater than or equal to the Length parameter.

Status

Required; 32-bit signed integer; output. Indicates the result of intrinsic execution. See the "Status Parameter" section, earlier in this chapter, for more information.

Description

The MCPostOnRcpt intrinsic causes LU 6.2 API to set up resources to check the contents of the receive buffer for the specified conversation. The MCTest or MCWait intrinsic can then be called to interrogate these resources and find out if any data has arrived for the conversation. See the descriptions of MCTest and MCWait, later in this chapter.

Once MCPostOnRcpt has executed successfully, posting is active. It remains active until something is received into the receive buffer or an intrinsic is called that ends posting and releases the resources. The following intrinsics end posting:

MCDeallocate
MCRcvAndWait
MCRcvNoWait
MCSendError

When the MCTest or MCWait intrinsic indicates that something is waiting in the receive buffer, call MCRcvAndWait or MCRcvNoWait with the same Data parameter you used in the last call to MCPostOnRcpt.

The MCPostOnRcpt intrinsic can be called only from Receive state. It can be called many times during the execution of a TP. If the Length parameter is changed from one call to the next, the Length value from the last call will be used to determine the minimum amount of data that must arrive before the TP is notified.

Status Info Values

 0    Successful Completion.
-1    Intrinsic called with parameter out of bounds.
-2    Invalid 'ResourceID' parameter specified in intrinsic call.
-11   Out of range 'Length' parameter specified in intrinsic call.
-20   Not enough stack space for intrinsic to run.
-40   Intrinsic called in invalid state.
-90   An internal error in Presentation Services has occurred.
-91   An internal error in the APPC subsystem has occurred.
-1002 An internal error at the mapped conversation level has occurred.
-1003 Required parameter missing.
-1050 Invalid 'Data' parameter specified in intrinsic call.
Feedback to webmaster