You are here

public function AcquiaPurgeQueueStatusInterface::setStatus in Acquia Purge 7

Set the status of the object.

Setting status on queue items is the responsibility of executors, as only executors decide what succeeded and what failed. For this reason a call to ::setStatusContext() before ::setStatus() is required and done by AcquiaPurgeService::process().

Parameters

int $status:

Throws

\RuntimeException Thrown when the $status parameter doesn't match any of the constants defined in AcquiaPurgeQueueStatusInterface.

\LogicException Thrown when trying to set the status before ::setStatusContext() has been called to set the executor context.

File

lib/queue/AcquiaPurgeQueueStatusInterface.php, line 89

Class

AcquiaPurgeQueueStatusInterface
Describes objects capable of letting multiple actors set a SUCCEEDED or FAILED status, which can then be evaluated to a single overall outcome.

Code

public function setStatus($status);