Manages the task queue and runs scheduled tasks.
Gets all tasks in the current queue.
An array of task instances.
public function getByName( |
| ) |
Gets tasks of the given class name. Note that this only gets exact matches. It will not get tasks that are a subclass of the given class
class_name | The full name, with namespace, of the desired class |
An array of task instances.
public function add( |
| ) |
Add a task to the queue.
task Task$ | The task to add. |
public function remove( |
| ) |
Removes a task from the queue.
task Task$ | The task to remove. |
public function findByKey( |
| ) |
Find a task that has the same key value as the parameter.
task Task$ | A task that has the desired key value. |
A Task instance or null if not found.
public function runPendingTasks( |
| ) |
Executes any tasks that are ready to be run. After executing, this will remove any tasks that indicate they should be deleted, i.e. one-shot tasks.