ClassesClassesClassesClasses | | | | Operators

get_message_paramget_message_paramGetMessageParamget_message_paramGetMessageParamGetMessageParam (Operator)

Name

get_message_paramget_message_paramGetMessageParamget_message_paramGetMessageParamGetMessageParam — Query message parameters or information about the message.

Signature

get_message_param( : : MessageHandle, GenParamName, Key : GenParamValue)

Herror get_message_param(const Hlong MessageHandle, const char* GenParamName, const char* Key, char* GenParamValue)

Herror T_get_message_param(const Htuple MessageHandle, const Htuple GenParamName, const Htuple Key, Htuple* GenParamValue)

Herror get_message_param(const HTuple& MessageHandle, const HTuple& GenParamName, const HTuple& Key, char* GenParamValue)

Herror get_message_param(const HTuple& MessageHandle, const HTuple& GenParamName, const HTuple& Key, HTuple* GenParamValue)

HTuple HMessage::GetMessageParam(const HTuple& GenParamName, const HTuple& Key) const

void GetMessageParam(const HTuple& MessageHandle, const HTuple& GenParamName, const HTuple& Key, HTuple* GenParamValue)

HTuple HMessage::GetMessageParam(const HString& GenParamName, const HTuple& Key) const

HTuple HMessage::GetMessageParam(const HString& GenParamName, const HString& Key) const

HTuple HMessage::GetMessageParam(const char* GenParamName, const char* Key) const

void HOperatorSetX.GetMessageParam(
[in] VARIANT MessageHandle, [in] VARIANT GenParamName, [in] VARIANT Key, [out] VARIANT* GenParamValue)

VARIANT HMessageX.GetMessageParam(
[in] BSTR GenParamName, [in] VARIANT Key)

static void HOperatorSet.GetMessageParam(HTuple messageHandle, HTuple genParamName, HTuple key, out HTuple genParamValue)

HTuple HMessage.GetMessageParam(string genParamName, HTuple key)

HTuple HMessage.GetMessageParam(string genParamName, string key)

Description

get_message_paramget_message_paramGetMessageParamget_message_paramGetMessageParamGetMessageParam queries current values of message parameters or other information about the message status.

With each call of get_message_paramget_message_paramGetMessageParamget_message_paramGetMessageParamGetMessageParam, only a single parameter value can be queried. However, there are two types of parameters/queries:

Key-independent (global) parameter names:

'message_keys'"message_keys""message_keys""message_keys""message_keys""message_keys":

Queries all the keys stored in the message, no matter whether they are associated with tuple or object data. The list of keys is reported as a string tuple via GenParamValueGenParamValueGenParamValueGenParamValueGenParamValuegenParamValue. For this query the parameter KeyKeyKeyKeyKeykey must be an empty tuple.

Currently supported key-specific parameter names are:

'key_exists'"key_exists""key_exists""key_exists""key_exists""key_exists":

Reports 1 if the given key is stored in the message, 0 otherwise. The results are reported via GenParamValueGenParamValueGenParamValueGenParamValueGenParamValuegenParamValue, one value for each key.

'key_data_type'"key_data_type""key_data_type""key_data_type""key_data_type""key_data_type":

Reports 'tuple'"tuple""tuple""tuple""tuple""tuple" for keys associated with tuple data within the message (the data can be retrieved using get_message_tupleget_message_tupleGetMessageTupleget_message_tupleGetMessageTupleGetMessageTuple). Reports 'object'"object""object""object""object""object" for keys associated with object data (the data can be retrieved using get_message_objget_message_objGetMessageObjget_message_objGetMessageObjGetMessageObj). The results are reported via GenParamValueGenParamValueGenParamValueGenParamValueGenParamValuegenParamValue, one value for each key. This parameter is useful to decide dynamically whether to use get_message_tupleget_message_tupleGetMessageTupleget_message_tupleGetMessageTupleGetMessageTuple or get_message_objget_message_objGetMessageObjget_message_objGetMessageObjGetMessageObj to get the data of a specific key.

Parallelization

Parameters

MessageHandleMessageHandleMessageHandleMessageHandleMessageHandlemessageHandle (input_control)  message HMessage, HTupleHTupleHMessage, HTupleHMessageX, VARIANTHtuple (integer) (IntPtr) (Hlong) (Hlong) (Hlong) (Hlong)

Message handle.

Number of elements: MessageHandle == 1

Restriction: MessageHandle != 0

GenParamNameGenParamNameGenParamNameGenParamNameGenParamNamegenParamName (input_control)  string HTupleHTupleHTupleVARIANTHtuple (string) (string) (HString) (char*) (BSTR) (char*)

Names of the message parameters or info queries.

Number of elements: GenParamName == GenParamValue

Default value: 'message_keys' "message_keys" "message_keys" "message_keys" "message_keys" "message_keys"

List of values: 'key_data_type'"key_data_type""key_data_type""key_data_type""key_data_type""key_data_type", 'key_exists'"key_exists""key_exists""key_exists""key_exists""key_exists", 'message_keys'"message_keys""message_keys""message_keys""message_keys""message_keys"

KeyKeyKeyKeyKeykey (input_control)  string(-array) HTupleHTupleHTupleVARIANTHtuple (string) (string) (HString) (char*) (BSTR) (char*)

Message keys the parameter/query should be applied to.

Restriction: length(Key) > 0

GenParamValueGenParamValueGenParamValueGenParamValueGenParamValuegenParamValue (output_control)  tuple(-array) HTupleHTupleHTupleVARIANTHtuple (string / integer / real) (string / int / long / double) (HString / Hlong / double) (char* / Hlong / double) (BSTR / Hlong / double) (char* / Hlong / double)

Values of the message parameters or info queries.

Example (HDevelop)

get_message_param (Message, 'message_keys', [], AllKeys)
get_message_param (Message, 'key_data_type', AllKeys, KeysType)

Result

If all the operator parameters, and the specified keys are valid, get_message_paramget_message_paramGetMessageParamget_message_paramGetMessageParamGetMessageParam returns 2 (H_MSG_TRUE). Otherwise an exception is raised.

Possible Predecessors

dequeue_messagedequeue_messageDequeueMessagedequeue_messageDequeueMessageDequeueMessage

See also

create_messagecreate_messageCreateMessagecreate_messageCreateMessageCreateMessage, clear_messageclear_messageClearMessageclear_messageClearMessageClearMessage, set_message_tupleset_message_tupleSetMessageTupleset_message_tupleSetMessageTupleSetMessageTuple, get_message_tupleget_message_tupleGetMessageTupleget_message_tupleGetMessageTupleGetMessageTuple, set_message_objset_message_objSetMessageObjset_message_objSetMessageObjSetMessageObj, get_message_objget_message_objGetMessageObjget_message_objGetMessageObjGetMessageObj, set_message_paramset_message_paramSetMessageParamset_message_paramSetMessageParamSetMessageParam, enqueue_messageenqueue_messageEnqueueMessageenqueue_messageEnqueueMessageEnqueueMessage, dequeue_messagedequeue_messageDequeueMessagedequeue_messageDequeueMessageDequeueMessage

Module

Foundation


ClassesClassesClassesClasses | | | | Operators