You are here

public function MemoryQueue::deleteItem in Purge 8.3

Deletes a finished item from the queue.

Parameters

$item: The item returned by \Drupal\Core\Queue\QueueInterface::claimItem().

Overrides QueueInterface::deleteItem

1 call to MemoryQueue::deleteItem()
MemoryQueue::deleteItemMultiple in src/Plugin/Purge/Queue/MemoryQueue.php
Delete multiple items from the queue at once.

File

src/Plugin/Purge/Queue/MemoryQueue.php, line 171

Class

MemoryQueue
A QueueInterface compliant volatile memory buffer queue.

Namespace

Drupal\purge\Plugin\Purge\Queue

Code

public function deleteItem($item) {
  $this
    ->bufferInitialize();
  if (!isset($this->buffer[$item->item_id])) {
    return FALSE;
  }
  unset($this->buffer[$item->item_id]);
}