MediaWiki REL1_40
|
Job queue task description base code. More...
Inherits IJobSpecification.
Public Member Functions | |
__construct ( $type, array $params, array $opts=[], PageReference $page=null) | |
getDeduplicationInfo () | |
Subclasses may need to override this to make duplication detection work. | |
getParams () | |
getReleaseTimestamp () | |
getRootJobParams () | |
getTitle () | |
getType () | |
hasRootJobParams () | |
ignoreDuplicates () | |
isRootJob () | |
toSerializableArray () | |
Static Public Member Functions | |
static | newFromArray (array $map) |
Protected Member Functions | |
validateParams (array $params) | |
Protected Attributes | |
array | $opts |
PageReference | $page |
array | $params |
Array of job parameters or false if none. | |
string | $type |
Job queue task description base code.
Example usage:
Definition at line 43 of file JobSpecification.php.
JobSpecification::__construct | ( | $type, | |
array | $params, | ||
array | $opts = [], | ||
PageReference | $page = null ) |
string | $type | |
array | $params | Map of key/values |
array | $opts | Map of key/values 'removeDuplicates' key - whether to remove duplicate jobs 'removeDuplicatesIgnoreParams' key - array with parameters to ignore for deduplication |
PageReference | null | $page |
Definition at line 64 of file JobSpecification.php.
References $type, MediaWiki\Page\PageReference\getDBkey(), MediaWiki\Page\PageReference\getNamespace(), NS_SPECIAL, and validateParams().
JobSpecification::getDeduplicationInfo | ( | ) |
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 129 of file JobSpecification.php.
References getParams(), and getType().
JobSpecification::getParams | ( | ) |
Implements IJobSpecification.
Definition at line 115 of file JobSpecification.php.
Referenced by getDeduplicationInfo().
JobSpecification::getReleaseTimestamp | ( | ) |
Implements IJobSpecification.
Definition at line 119 of file JobSpecification.php.
References wfTimestampOrNull().
JobSpecification::getRootJobParams | ( | ) |
Implements IJobSpecification.
Definition at line 150 of file JobSpecification.php.
JobSpecification::getTitle | ( | ) |
Definition at line 110 of file JobSpecification.php.
References wfDeprecated().
JobSpecification::getType | ( | ) |
Implements IJobSpecification.
Definition at line 102 of file JobSpecification.php.
References $type.
Referenced by getDeduplicationInfo().
JobSpecification::hasRootJobParams | ( | ) |
Implements IJobSpecification.
Definition at line 157 of file JobSpecification.php.
Referenced by isRootJob().
JobSpecification::ignoreDuplicates | ( | ) |
Implements IJobSpecification.
Definition at line 125 of file JobSpecification.php.
JobSpecification::isRootJob | ( | ) |
Implements IJobSpecification.
Definition at line 162 of file JobSpecification.php.
References hasRootJobParams().
|
static |
array | $map | Field/value map |
Definition at line 187 of file JobSpecification.php.
JobSpecification::toSerializableArray | ( | ) |
Definition at line 170 of file JobSpecification.php.
References $type.
|
protected |
array | $params |
Definition at line 92 of file JobSpecification.php.
References validateParams().
Referenced by __construct(), and validateParams().
|
protected |
Definition at line 54 of file JobSpecification.php.
|
protected |
Definition at line 51 of file JobSpecification.php.
|
protected |
Array of job parameters or false if none.
Definition at line 48 of file JobSpecification.php.
|
protected |
Definition at line 45 of file JobSpecification.php.