MQ_DATA_CONV_EXIT call, MsgDesc parameter, InBufferLength parameter, InBuffer parameter, OutBufferLength parameter, OutBuffer parameter" /> Parameters
Home

 

Parameters

The MQ_DATA_CONV_EXIT call has the following parameters.

 

DataConvExitParms (MQDXP) - input/output

Data-conversion exit parameter block.

This structure contains information relating to the invocation of the exit. The exit sets information in this structure to indicate the outcome of the conversion. See MQDXP - Data-conversion exit parameter for details of the fields in this structure.

 

MsgDesc (MQMD) - input/output

Message descriptor.

On input to the exit, this is the message descriptor associated with the message data passed to the exit in the InBuffer parameter.

Note:
The MsgDesc parameter passed to the exit is always the most-recent version of MQMD supported by the queue manager which invokes the exit. If the exit is intended to be portable between different environments, the exit should check the Vfield in MsgDesc to verify that the fields that the exit needs to access are present in the structure.

In the following environments, the exit is passed a version-2 MQMD: AIX, HP-UX, OS/2, i5/OS, Solaris, Linux, Windows. In all other environments that support the data conversion exit, the exit is passed a version-1 MQMD.

On output, the exit should change the Encoding and CodedCharSetId fields to the values requested by the application, if conversion was successful; these changes will be reflected back to the application. Any other changes that the exit makes to the structure are ignored; they are not reflected back to the application.

If the exit returns MQXDR_OK in the ExitResponse field of the MQDXP structure, but does not change the Encoding or CodedCharSetId fields in the message descriptor, the queue manager returns for those fields the values that the corresponding fields in the MQDXP structure had on input to the exit.

 

InBufferLength (MQLONG) - input

Length in bytes of InBuffer.

This is the length of the input buffer InBuffer, and specifies the number of bytes to be processed by the exit. InBufferLength is the lesser of the length of the message data prior to conversion, and the length of the buffer provided by the application on the MQGET call.

The value is always greater than zero.

 

InBuffer (MQBYTE×InBufferLength) - input

Buffer containing the unconverted message.

This contains the message data prior to conversion. If the exit is unable to convert the data, the queue manager returns the contents of this buffer to the application after the exit has completed.

Note:
The exit should not alter InBuffer; if this parameter is altered, the results are undefined.

In the C programming language, this parameter is defined as a pointer-to-void.

 

OutBufferLength (MQLONG) - input

Length in bytes of OutBuffer.

This is the length of the output buffer OutBuffer, and is the same as the length of the buffer provided by the application on the MQGET call.

The value is always greater than zero.

 

OutBuffer (MQBYTE×OutBufferLength) - output

Buffer containing the converted message.

On output from the exit, if the conversion was successful (as indicated by the value MQXDR_OK in the ExitResponse field of the DataConvExitParms parameter), OutBuffer contains the message data to be delivered to the application, in the requested representation. If the conversion was unsuccessful, any changes that the exit has made to this buffer are ignored.

In the C programming language, this parameter is defined as a pointer-to-void.



 

Home