OSI/MHS P7 Application Programmatic Interface (P7 API) Manual
Procedure Calls
OSI/MHS P7 Application Programmatic Interface (P7 API) Manual—424825-001
3-16
LOS_OPEN_
sendFileNum  output
extptr int *
returns a file number to be used by the client application to send data to OSI/MHS. 
A return file number of -1 indicates that an error has occurred.  You should call 
LOS_DT_FINISH_SEND_ when sendFileNum is returned to the client 
application from a call to AWAITIOX.
resultFileNum  output
extptr int *
returns a file number to be used by the client application to receive data from 
OSI/MHS.  A return file number of -1 indicates that an error has occurred. You 
should call LOS_DT_FINISH_RESULT_ when resultFileNum is returned to 
the client application from a call to AWAITIOX.
Considerations
•
You must open a session with LOS_OPEN_ before you can use any of the 
data-transfer procedures.
•
The maximum number of concurrent sessions is determined by the value specified 
in ZMHS-VAL-LOUAPI-MAX-NUM-SESS.
•
The P7 API chooses the LO group to open by selecting the one with the least 
number of associations.
•
The client application must allocate the buffers used by the P7 API before the call to 
LOS_OPEN_ and delete them after a call to LOS_CLOSE_ . These buffers are for 
the use of the P7 API and cannot not be used by the client application. You can 
declare these buffers either dynamically or statically. For information on allocating 
buffers, see the C Reference Manual.
•
buffer1Ptr and buffer2Ptr are used by the P7 API to make calls to the 
Guardian WRITEREADX procedure. Because the P7 API uses these buffers 
alternately, the validity of the data returned from LOS_DT_FINISH_RESULT_ can 
be guaranteed only until the next call to LOS_DT_FINISH_RESULT_ .
•
When declaring a structure to hold the mhsMgrName, you should note that a fully 
qualified process name can have up to 35 characters plus a null termination 
character for C strings.  Additionally, you might want to declare a variable to hold 
the name of the MHS manager process and read in the actual name during execution 
of your program. For an example that illustrates these two points, see the sample 
program in Appendix E.










