TsgcWSPClient_AMQPMethods › PurgeQueue

PurgeQueue Method

Removes all pending messages from a queue (queue.purge).

Syntax

procedure PurgeQueue(const aChannel, aQueue: string; aNoWait: Boolean = false);

Parameters

NameTypeDescription
aChannelconst stringName of the open AMQP channel on which the operation is issued.
aQueueconst stringName of the queue.
aNoWaitBooleanWhen True the client does not wait for the broker to confirm the operation.

Remarks

Discards every ready message in the queue. Messages delivered but not yet acknowledged are not affected.

Example

sgcWSPClient_AMQP1.PurgeQueue('ch1', 'orders');

Back to Methods