From: Thiemo Mättig Date: Fri, 15 Jan 2016 09:31:07 +0000 (+0100) Subject: Fix mistakes in JobQueue type documentations X-Git-Tag: 1.31.0-rc.0~8318^2 X-Git-Url: http://git.cyclocoop.org/%7B%24admin_url%7Dmes_infos.php?a=commitdiff_plain;h=d22a14639364dc7f8e0d796f164c0f6c682d7640;p=lhc%2Fweb%2Fwiklou.git Fix mistakes in JobQueue type documentations The missing "bool" should be obvious. I'm also changing type hints from the implementation to the interface. All public methods from the JobSpecification class are also in the interface, except for two: toSerializableArray and newFromArray. These two are not used here. Change-Id: I36867cdfdf012a4f3233ac4730ab46dac1edc0ab --- diff --git a/includes/jobqueue/JobQueue.php b/includes/jobqueue/JobQueue.php index 89948f46ba..3ff2724e94 100644 --- a/includes/jobqueue/JobQueue.php +++ b/includes/jobqueue/JobQueue.php @@ -286,7 +286,7 @@ abstract class JobQueue { * This does not require $wgJobClasses to be set for the given job type. * Outside callers should use JobQueueGroup::push() instead of this function. * - * @param JobSpecification|JobSpecification[] $jobs + * @param IJobSpecification|IJobSpecification[] $jobs * @param int $flags Bitfield (supports JobQueue::QOS_ATOMIC) * @return void * @throws JobQueueError @@ -301,7 +301,7 @@ abstract class JobQueue { * This does not require $wgJobClasses to be set for the given job type. * Outside callers should use JobQueueGroup::push() instead of this function. * - * @param JobSpecification[] $jobs + * @param IJobSpecification[] $jobs * @param int $flags Bitfield (supports JobQueue::QOS_ATOMIC) * @return void * @throws MWException @@ -333,7 +333,7 @@ abstract class JobQueue { /** * @see JobQueue::batchPush() - * @param JobSpecification[] $jobs + * @param IJobSpecification[] $jobs * @param int $flags */ abstract protected function doBatchPush( array $jobs, $flags ); @@ -377,7 +377,7 @@ abstract class JobQueue { /** * @see JobQueue::pop() - * @return Job + * @return Job|bool */ abstract protected function doPop(); diff --git a/includes/jobqueue/JobQueueRedis.php b/includes/jobqueue/JobQueueRedis.php index 546093f4d9..eda3e9ccc3 100644 --- a/includes/jobqueue/JobQueueRedis.php +++ b/includes/jobqueue/JobQueueRedis.php @@ -186,7 +186,7 @@ class JobQueueRedis extends JobQueue { /** * @see JobQueue::doBatchPush() - * @param array $jobs + * @param IJobSpecification[] $jobs * @param int $flags * @return void * @throws JobQueueError