April 2002
Intermediate to advanced
318 pages
6h 58m
English
Here we present some of the advance functionality of the C++ API, specifically the browsing messages functionality, and the inquiring and setting object attributes functionality.
Messages on a queue can be browsed using an ImqQueue get method. The ImqQueue object must be open using the MQOO_BROWSE open option. That can be done using the setOpenOptions or the openFor method as described in “Opening queues” on page 139.
pqueue.setOpenOptions(MQOO_BROWSE);
or
pqueue.openFor(MQOO_BROWSE);
After the queue object has been opened for browse, the ImqQueue get method has to be called with an ImqGetMessageOptions object with the following options:
MQGMO_BROWSE_FIRST message option, if you want ...
Read now
Unlock full access