public function BatchQueue::getAllItems

public BatchQueue::getAllItems()

Retrieves all remaining items in the queue.

This is specific to Batch API and is not part of the DrupalQueueInterface.

File

includes/batch.queue.inc, line 42
Queue handlers used by the Batch API.

Class

BatchQueue
Defines a batch queue.

Code

public function getAllItems() {
  $result = array();
  $items = db_query('SELECT data FROM {queue} q WHERE name = :name ORDER BY item_id ASC', array(':name' => $this->name))->fetchAll();
  foreach ($items as $item) {
    $result[] = unserialize($item->data);
  }
  return $result;
}

© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/includes!batch.queue.inc/function/BatchQueue::getAllItems/7.x