The Dequeue method retrieves the next item from the server
FIFO (first in, first out) queue.
If the optional Remove parameter is True, the item is
removed from the queue and the memory that was allocated for it is
released. If the parameter is false, then a copy of the item data is
returned, but it is not removed from the queue. This allows an
application to peek at the next item in the queue without removing
it. The server queue methods are thread-safe and each update to the
queue is an atomic operation. This enables an application to easily
exchange information with other client sessions, or even other
servers.
To obtain the number of items in the server queue, use the
QueueCount property. To remove all items from the queue, use
the ClearQueue method.
Note that queued items are only available while the server is
active. Once the server has been stopped, any queued items are
automatically removed and the memory allocated for the queue is
released.