MediaWiki
REL1_24
|
Job queue task description base code. More...
Public Member Functions | |
__construct ($type, array $params, array $opts=array(), Title $title=null) | |
getDeduplicationInfo () | |
Subclasses may need to override this to make duplication detection work. | |
getParams () | |
getReleaseTimestamp () | |
getTitle () | |
getType () | |
ignoreDuplicates () | |
Protected Member Functions | |
validateParams (array $params) | |
Protected Attributes | |
bool | $ignoreDuplicates |
Expensive jobs may set this to true *. | |
array | $params |
Array of job parameters or false if none *. | |
Title | $title |
* | |
string | $type |
* |
Job queue task description base code.
Example usage: $job = new JobSpecification( 'null', array( 'lives' => 1, 'usleep' => 100, 'pi' => 3.141569 ), array( 'removeDuplicates' => 1 ), Title::makeTitle( NS_SPECIAL, 'nullity' ) ); JobQueueGroup::singleton()->push( $job )
Definition at line 84 of file JobSpecification.php.
JobSpecification::__construct | ( | $ | type, |
array $ | params, | ||
array $ | opts = array() , |
||
Title $ | title = null |
||
) |
string | $type | |
array | $params | Map of key/values |
array | $opts | Map of key/values |
Title | $title | Optional descriptive title |
Definition at line 99 of file JobSpecification.php.
Subclasses may need to override this to make duplication detection work.
The resulting map conveys everything that makes the job unique. This is only checked if ignoreDuplicates() returns true, meaning that duplicate jobs are supposed to be ignored.
Implements IJobSpecification.
Definition at line 168 of file JobSpecification.php.
Implements IJobSpecification.
Definition at line 147 of file JobSpecification.php.
References wfTimestampOrNull().
Implements IJobSpecification.
Definition at line 133 of file JobSpecification.php.
References title.
Implements IJobSpecification.
Definition at line 126 of file JobSpecification.php.
References type.
Implements IJobSpecification.
Definition at line 156 of file JobSpecification.php.
JobSpecification::validateParams | ( | array $ | params | ) | [protected] |
bool JobSpecification::$ignoreDuplicates [protected] |
Expensive jobs may set this to true *.
Definition at line 91 of file JobSpecification.php.
array JobSpecification::$params [protected] |
Array of job parameters or false if none *.
Definition at line 87 of file JobSpecification.php.
*
Definition at line 89 of file JobSpecification.php.
string JobSpecification::$type [protected] |
*
Definition at line 85 of file JobSpecification.php.