Provides fields storing standard message property names.
public class MessageProperties
All members of MessageProperties class, including all inherited members.
Name | Description |
---|---|
This property name refers to the currently active network adapter that is being used to connect to the QAnywhere server. | |
This property name refers to a delimited list of network adapters that can be used to connect to the QAnywhere server. | |
This property name refers to the number of attempts that have been made so far to deliver the message. | |
This property name refers to the IP address of the currently active network adapter that is being used to connect to the QAnywhere server. | |
This property name refers to the MAC address of the currently active network adapter that is being used to connect to the QAnywhere server. | |
This property name refers to MessageType enumeration values associated with a QAnywhere message. | |
This property name refers to the state of the network connection. | |
This property name refers to the message store ID of the originator of the message. | |
This property name refers to the currently active RAS name that is being used to connect to the QAnywhere server. | |
This property name refers to a delimited list of RAS entry names that can be used to connect to the QAnywhere server. | |
This property name refers to the current status of the message. | |
This property name refers to the time at which the message received its current status. | |
This property name refers to the current transmission status of the message. |
The MessageProperties class provides standard message property names. You can pass MessageProperties fields to QAMessage methods used to get and set message properties.
For more information, see QAnywhere messages.
For example, assume you have the following QATextMessage instance:
QATextMessage * t_msg; |
The following example gets the value corresponding to MessageProperties::MSG_TYPE using the QAMessage::getIntProperty method. The MessageType enumeration maps the integer result to an appropriate message type.
int msg_type; t_msg->getIntProperty( MessageProperties::MSG_TYPE, &msg_type) |
The following example, evaluates the message type and RAS names using MessageProperties::MSG_TYPE and MessageProperties::RASNAMES respectively.
void SystemQueueListener::onMessage(QAMessage * msg) { QATextMessage * t_msg; TCHAR buffer[512]; int len; int msg_type; t_msg = msg->castToTextMessage(); if( t_msg != NULL ) { t_msg->getIntProperty( MessageProperties::MSG_TYPE, &msg_type ); if( msg_type == MessageType::NETWORK_STATUS_NOTIFICATION ) { // get RAS names using MessageProperties::RASNAMES len = t_msg->getStringProperty(MessageProperties::RASNAMES,buffer,sizeof(buffer)); } //... } } |
ADAPTER variable
ADAPTERS variable
DELIVERY_COUNT variable
IP variable
MAC variable
MSG_TYPE variable
NETWORK_STATUS variable
ORIGINATOR variable
RAS variable
RASNAMES variable
STATUS variable
STATUS_TIME variable
TRANSMISSION_STATUS variable
Discuss this page in DocCommentXchange.
|
Copyright © 2010, iAnywhere Solutions, Inc. - SQL Anywhere 12.0.0 |