Chapter 10 Queue Browser : tibemsQueueBrowser

tibemsQueueBrowser
Type
Purpose
View the messages in a queue without consuming them.
Remarks
A browser is a dynamic enumerator of the queue (not a static snapshot). The queue is at the server, and its contents change as message arrive and consumers remove them. Meanwhile, while the browser is at the client. The function tibemsQueueBrowser_GetNext gets the next message from the server.
The browser can enumerate messages in a queue, or a subset filtered by a message selector.
Sessions serve as factories for queue browsers; see tibemsSession_CreateBrowser on page 291.
 
See Also
tibemsSession_CreateBrowser on page 291
tibemsQueueBrowser_Close
Function
Purpose
Close the browser; reclaim resources.
C Declaration
tibems_status tibemsQueueBrowser_Close(
    tibemsQueueBrowser queueBrowser );
COBOL Call
CALL "tibemsQueueBrowser_Close"
USING BY VALUE queueBrowser,
RETURNING tibems-status
END-CALL.
 
queueBrowser has usage pointer.
Parameters
 
tibemsQueueBrowser_GetMsgSelector
Function
Purpose
Get the selector string for the browser.
C Declaration
tibems_status tibemsQueueBrowser_GetMsgSelector(
    tibemsQueueBrowser queueBrowser,
    const char** selector );
COBOL Call
CALL "tibemsQueueBrowser_GetMsgSelector"
USING BY VALUE queueBrowser,
BY REFERENCE selector,
RETURNING tibems-status
END-CALL.
 
queueBrowser and selector have usage pointer.
Parameters
 
Remarks
When non-null, the browser presents only messages that match this selector; see Message Selectors.
When null, or the empty string, the browser views all messages in the queue.
tibemsQueueBrowser_GetNext
Function
Purpose
Get the next message from the browser.
C Declaration
tibems_status tibemsQueueBrowser_GetNext(
    tibemsQueueBrowser queueBrowser,
    tibemsMsg* msg );
COBOL Call
CALL "tibemsQueueBrowser_GetNext"
USING BY VALUE queueBrowser,
BY REFERENCE msg,
RETURNING tibems-status
END-CALL.
 
queueBrowser and msg have usage pointer.
Parameters
 
Remarks
A browser is a dynamic enumerator of the queue (not a static snapshot). The queue is at the server, and its contents change as message arrive and consumers remove them. Meanwhile, while the browser is at the client. This function gets the next message from the server.
If prior calls to this function have exhausted the messages in the queue, the function returns TIBEMS_NOT_FOUND.
tibemsQueueBrowser_GetQueue
Function
Purpose
Get the queue that the browser examines.
C Declaration
tibems_status tibemsQueueBrowser_GetQueue(
    tibemsQueueBrowser queueBrowser,
    tibemsQueue* queue );
COBOL Call
CALL "tibemsQueueBrowser_GetQueue"
USING BY VALUE queueBrowser,
BY REFERENCE queue,
RETURNING tibems-status
END-CALL.
 
queueBrowser and queue have usage pointer.
Parameters