Merge "Improve param docs and add @var to clarify types"

This commit is contained in:
jenkins-bot 2019-02-17 01:29:48 +00:00 committed by Gerrit Code Review
commit 3fd6549ced
4 changed files with 13 additions and 7 deletions

View file

@ -9,7 +9,7 @@ class EchoUserLocator {
*
* @param EchoEvent $event
* @param int $batchSize
* @return User[]
* @return User[]|Iterator<User>
*/
public static function locateUsersWatchingTitle( EchoEvent $event, $batchSize = 500 ) {
$title = $event->getTitle();

View file

@ -141,7 +141,7 @@ class ApiEchoNotifications extends ApiQueryBase {
* Internal method for getting the property 'list' data for individual section
* @param User $user
* @param string $section 'alert' or 'message'
* @param string $filter 'all', 'read' or 'unread'
* @param string[] $filter 'all', 'read' or 'unread'
* @param int $limit
* @param string $continue
* @param string $format
@ -184,7 +184,7 @@ class ApiEchoNotifications extends ApiQueryBase {
* of a set of sections or a single section
* @param User $user
* @param string[] $eventTypes
* @param string $filter 'all', 'read' or 'unread'
* @param string[] $filter 'all', 'read' or 'unread'
* @param int $limit
* @param string $continue
* @param string $format

View file

@ -1,6 +1,7 @@
<?php
class EchoNotificationJob extends Job {
/** @var int */
private $eventId;
public function __construct( $title, $params ) {

View file

@ -8,34 +8,39 @@ use MediaWiki\Logger\LoggerFactory;
*/
class EchoEvent extends EchoAbstractEntity implements Bundleable {
/** @var string|null */
protected $type = null;
/** @var string|null|false */
protected $id = null;
/** @var string|null */
protected $variant = null;
/**
* @var User
* @var User|null
*/
protected $agent = null;
/**
* Loaded dynamically on request
*
* @var Title
* @var Title|null
*/
protected $title = null;
/** @var int|null */
protected $pageId = null;
/**
* Loaded dynamically on request
*
* @var Revision
* @var Revision|null
*/
protected $revision = null;
/** @var array */
protected $extra = [];
/**
* Notification timestamp
* @var string
* @var string|null
*/
protected $timestamp = null;