class PurgePurgerBundleQueue in Purge 7.2
Executes queued purges.
This is a minimal bundle, containing just the handlers needed to process all queued purges.
Hierarchy
- class \Purge
- class \PurgePurger
- class \PurgePurgerBundle
- class \PurgePurgerBundleQueue
- class \PurgePurgerBundle
- class \PurgePurger
Expanded class hierarchy of PurgePurgerBundleQueue
File
- includes/
purge.class.inc, line 1017 - Contains all class and interface definitions for Purge.
View source
class PurgePurgerBundleQueue extends PurgePurgerBundle {
/**
* Constructs the bundle from queue items and executes the purges.
*
* @param array $queue_items
*/
public function __construct($queue_items) {
// Get the raw data from the variable (or cache at a later stage).
$all_data = $this
->get_data();
// Figure out which handlers we'll need for these purges.
foreach ($queue_items as $queue_item) {
$handler_name = $queue_item['handler'];
if (!isset($this->handler[$handler_name])) {
// Create the object from the serialized data.
$this->handler[$handler_name] = unserialize($all_data['handler'][$handler_name]);
}
}
}
/**
* Executes all queueditems with their handlers.
*/
public function execute($queue_items) {
// Execute all queue items to the handlers.
foreach ($queue_items as $queue_item) {
$handler_name = $queue_item['handler'];
$this->handler[$handler_name]
->execute($queue_item['purges'], $queue_item['handler_options']);
}
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
Purge:: |
public | property | ||
Purge:: |
public | property | ||
Purge:: |
public | property | ||
Purge:: |
public | property | ||
Purge:: |
public | property | ||
Purge:: |
public | property | ||
Purge:: |
public | property | ||
Purge:: |
public | property | ||
Purge:: |
public | function | Does basic dependency checks for builtin dependencies. | 5 |
PurgePurger:: |
public | property | ||
PurgePurger:: |
public | property | ||
PurgePurger:: |
public | property | ||
PurgePurger:: |
public | property | ||
PurgePurger:: |
public | property | ||
PurgePurgerBundle:: |
public | property | ||
PurgePurgerBundle:: |
public | function | Function to select data from the dataset. | |
PurgePurgerBundle:: |
public | function | Function to set the type objects. | |
PurgePurgerBundle:: |
public | function |
Override for parents sleep to make sure we include the bundled objects. Overrides Purge:: |
|
PurgePurgerBundle:: |
public | function | Set the item objects linked in this bundle when waking up. | |
PurgePurgerBundleQueue:: |
public | function | Executes all queueditems with their handlers. | |
PurgePurgerBundleQueue:: |
public | function | Constructs the bundle from queue items and executes the purges. |