MediaWiki REL1_39
|
DeferredUpdates helper class for managing DeferrableUpdate::doUpdate() nesting levels caused by nested calls to DeferredUpdates::doUpdates() More...
Public Member Functions | |
addUpdate (DeferrableUpdate $update, $stage) | |
Enqueue a deferred update within this scope using the specified "defer until" time. | |
clearPendingUpdates () | |
Cancel all pending updates within this scope. | |
consumeMatchingUpdates ( $stage, $class, callable $callback) | |
Remove pending updates of the specified stage/class and pass them to a callback. | |
getActiveUpdate () | |
Get the deferred update that owns this scope (root scope has none) | |
getPendingUpdates ( $stage) | |
Get pending updates within this scope with the given "defer until" stage. | |
pendingUpdatesCount () | |
Get the number of pending updates within this scope. | |
processUpdates ( $stage, callable $callback) | |
Iteratively, reassign unready pending updates to the parent scope (if applicable) and process the ready pending updates in stage-order with the callback, repeating the process until there is nothing left to do. | |
Static Public Member Functions | |
static | newChildScope ( $activeStage, DeferrableUpdate $update, DeferredUpdatesScope $parentScope) |
static | newRootScope () |
DeferredUpdates helper class for managing DeferrableUpdate::doUpdate() nesting levels caused by nested calls to DeferredUpdates::doUpdates()
Definition at line 30 of file DeferredUpdatesScope.php.
DeferredUpdatesScope::addUpdate | ( | DeferrableUpdate | $update, |
$stage ) |
Enqueue a deferred update within this scope using the specified "defer until" time.
DeferrableUpdate | $update | |
int | $stage | One of DeferredUpdates::STAGES |
Definition at line 92 of file DeferredUpdatesScope.php.
References $queue.
DeferredUpdatesScope::clearPendingUpdates | ( | ) |
Cancel all pending updates within this scope.
Definition at line 146 of file DeferredUpdatesScope.php.
DeferredUpdatesScope::consumeMatchingUpdates | ( | $stage, | |
$class, | |||
callable | $callback ) |
Remove pending updates of the specified stage/class and pass them to a callback.
int | $stage | One of DeferredUpdates::STAGES or DeferredUpdates::ALL |
string | $class | Only take updates of this fully qualified class/interface name |
callable | $callback | Callback that takes DeferrableUpdate |
Definition at line 157 of file DeferredUpdatesScope.php.
References $queue.
DeferredUpdatesScope::getActiveUpdate | ( | ) |
Get the deferred update that owns this scope (root scope has none)
Definition at line 82 of file DeferredUpdatesScope.php.
DeferredUpdatesScope::getPendingUpdates | ( | $stage | ) |
Get pending updates within this scope with the given "defer until" stage.
int | $stage | One of DeferredUpdates::STAGES or DeferredUpdates::ALL |
Definition at line 132 of file DeferredUpdatesScope.php.
References $queue.
|
static |
int | $activeStage | The in-progress stage; one of DeferredUpdates::STAGES |
DeferrableUpdate | $update | The deferred update that owns this scope |
DeferredUpdatesScope | $parentScope | The parent scope of this scope |
Definition at line 69 of file DeferredUpdatesScope.php.
Referenced by DeferredUpdatesScopeStack\descend().
|
static |
Definition at line 59 of file DeferredUpdatesScope.php.
Referenced by DeferredUpdatesScopeStack\__construct().
DeferredUpdatesScope::pendingUpdatesCount | ( | ) |
Get the number of pending updates within this scope.
Definition at line 122 of file DeferredUpdatesScope.php.
DeferredUpdatesScope::processUpdates | ( | $stage, | |
callable | $callback ) |
Iteratively, reassign unready pending updates to the parent scope (if applicable) and process the ready pending updates in stage-order with the callback, repeating the process until there is nothing left to do.
int | $stage | One of DeferredUpdates::STAGES or DeferredUpdates::ALL |
callable | $callback | Processing function with arguments (update, effective stage) |
Definition at line 184 of file DeferredUpdatesScope.php.