Copyright © TIBCO Software Inc. All Rights Reserved
Copyright © TIBCO Software Inc. All Rights Reserved


Chapter 2 Messages : tibemsBytesMsg : tibemsBytesMsg_ReadBytes

tibemsBytesMsg_ReadBytes
Function
Purpose
Read bytes to a byte sequence from the byte stream in the message body.
C Declaration
tibems_status tibemsBytesMsg_ReadBytes(
    tibemsBytesMsg message,
    const void** value,
    tibems_int   requested_length,
    tibems_int*  return_length );
COBOL Call
CALL "tibemsBytesMsg_ReadBytes"
 USING BY VALUE message,
       BY REFERENCE value,
       BY VALUE requested-length,
       BY REFERENCE return-length,
       RETURNING tibems-status
END-CALL.
 
message and value have usage pointer.
Parameters
 
The function stores in this location the actual number of bytes that it read. (If the number of bytes remaining in the message is less than the requested_length, then this location indicates that number of remaining bytes. Your program must not use bytes beyond this limit.)
When the function cannot read even one byte, it stores -1 in this location (and returns a successful status code).
Remarks
Each call reads bytes from the stream into the byte array, and advances the read position.

Copyright © TIBCO Software Inc. All Rights Reserved
Copyright © TIBCO Software Inc. All Rights Reserved