Mattflaschen has uploaded a new change for review. (
https://gerrit.wikimedia.org/r/351570 )
Change subject: Fix all the Doxygen for the RCFilters backend
......................................................................
Fix all the Doxygen for the RCFilters backend
Bug: T163069
Change-Id: I7a8c95efaff7c844e32e4375dfe6af8c2e91923f
---
M includes/changes/ChangesListBooleanFilter.php
M includes/changes/ChangesListBooleanFilterGroup.php
M includes/changes/ChangesListFilter.php
M includes/changes/ChangesListFilterGroup.php
M includes/changes/ChangesListStringOptionsFilterGroup.php
M includes/specialpage/ChangesListSpecialPage.php
6 files changed, 101 insertions(+), 113 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core
refs/changes/70/351570/1
diff --git a/includes/changes/ChangesListBooleanFilter.php
b/includes/changes/ChangesListBooleanFilter.php
index 1c116ab..f4299c2 100644
--- a/includes/changes/ChangesListBooleanFilter.php
+++ b/includes/changes/ChangesListBooleanFilter.php
@@ -30,12 +30,6 @@
* @since 1.29
*/
class ChangesListBooleanFilter extends ChangesListFilter {
- /**
- * Name. Used as URL parameter
- *
- * @var string $name
- */
-
// This can sometimes be different on Special:RecentChanges
// and Special:Watchlist, due to the double-legacy hooks
// (SpecialRecentChangesFilters and SpecialWatchlistFilters)
@@ -84,32 +78,31 @@
* it's for.
*
* @param array $filterDefinition ChangesListFilter definition
- *
- * $filterDefinition['name'] string Name. Used as URL parameter.
- * $filterDefinition['group'] ChangesListFilterGroup Group. Filter
group this
- * belongs to.
- * $filterDefinition['label'] string i18n key of label for structured
UI.
- * $filterDefinition['description'] string i18n key of description for
structured
- * UI.
- * $filterDefinition['showHide'] string Main i18n key used for
unstructured UI.
- * $filterDefinition['isReplacedInStructuredUi'] bool Whether there is
an
- * equivalent feature available in the structured UI; this is
optional, defaulting
- * to true. It does not need to be set if the exact same filter is
simply visible
- * on both.
- * $filterDefinition['default'] bool Default
- * $filterDefinition['priority'] int Priority integer. Higher value
means higher
- * up in the group's filter list.
- * $filterDefinition['queryCallable'] callable Callable accepting
parameters, used
- * to implement filter's DB query modification. Callback parameters:
- * string $specialPageClassName Class name of current special page
- * IContextSource $context Context, for e.g. user
- * IDatabase $dbr Database, for addQuotes, makeList, and similar
- * array &$tables Array of tables; see IDatabase::select $table
- * array &$fields Array of fields; see IDatabase::select $vars
- * array &$conds Array of conditions; see IDatabase::select $conds
- * array &$query_options Array of query options; see
IDatabase::select $options
- * array &$join_conds Array of join conditions; see IDatabase::select
$join_conds
- * Optional only for legacy filters that still use the query hooks
directly
+ * * $filterDefinition['name'] string Name. Used as URL parameter.
+ * * $filterDefinition['group'] ChangesListFilterGroup Group. Filter
group this
+ * belongs to.
+ * * $filterDefinition['label'] string i18n key of label for structured
UI.
+ * * $filterDefinition['description'] string i18n key of description
for structured
+ * UI.
+ * * $filterDefinition['showHide'] string Main i18n key used for
unstructured UI.
+ * * $filterDefinition['isReplacedInStructuredUi'] bool Whether there
is an
+ * equivalent feature available in the structured UI; this is
optional, defaulting
+ * to true. It does not need to be set if the exact same filter is
simply visible
+ * on both.
+ * * $filterDefinition['default'] bool Default
+ * * $filterDefinition['priority'] int Priority integer. Higher value
means higher
+ * up in the group's filter list.
+ * * $filterDefinition['queryCallable'] callable Callable accepting
parameters, used
+ * to implement filter's DB query modification. Required, except
for legacy
+ * filters that still use the query hooks directly. Callback
parameters:
+ * * string $specialPageClassName Class name of current special
page
+ * * IContextSource $context Context, for e.g. user
+ * * IDatabase $dbr Database, for addQuotes, makeList, and similar
+ * * array &$tables Array of tables; see IDatabase::select $table
+ * * array &$fields Array of fields; see IDatabase::select $vars
+ * * array &$conds Array of conditions; see IDatabase::select
$conds
+ * * array &$query_options Array of query options; see
IDatabase::select $options
+ * * array &$join_conds Array of join conditions; see
IDatabase::select $join_conds
*/
public function __construct( $filterDefinition ) {
parent::__construct( $filterDefinition );
@@ -150,7 +143,7 @@
/**
* Sets default
*
- * @param bool Default value
+ * @param bool $defaultValue Default value
*/
public function setDefault( $defaultValue ) {
$this->defaultValue = $defaultValue;
diff --git a/includes/changes/ChangesListBooleanFilterGroup.php
b/includes/changes/ChangesListBooleanFilterGroup.php
index 1f4b211..951c407 100644
--- a/includes/changes/ChangesListBooleanFilterGroup.php
+++ b/includes/changes/ChangesListBooleanFilterGroup.php
@@ -19,21 +19,21 @@
* @param array $groupDefinition Configuration of group
* * $groupDefinition['name'] string Group name
* * $groupDefinition['title'] string i18n key for title (optional, can
be omitted
- * * only if none of the filters in the group display in the
structured UI)
+ * only if none of the filters in the group display in the
structured UI)
* * $groupDefinition['priority'] int Priority integer. Higher means
higher in the
- * * group list.
+ * group list.
* * $groupDefinition['filters'] array Numeric array of filter
definitions, each of which
- * * is an associative array to be passed to the filter constructor.
However,
- * * 'priority' is optional for the filters. Any filter that has
priority unset
- * * will be put to the bottom, in the order given.
+ * is an associative array to be passed to the filter constructor.
However,
+ * 'priority' is optional for the filters. Any filter that has
priority unset
+ * will be put to the bottom, in the order given.
* * $groupDefinition['whatsThisHeader'] string i18n key for header of
"What's
- * * This" popup (optional).
+ * This" popup (optional).
* * $groupDefinition['whatsThisBody'] string i18n key for body of
"What's This"
- * * popup (optional).
+ * popup (optional).
* * $groupDefinition['whatsThisUrl'] string URL for main link of
"What's This"
- * * popup (optional).
+ * popup (optional).
* * $groupDefinition['whatsThisLinkText'] string i18n key of text for
main link of
- * * "What's This" popup (optional).
+ * "What's This" popup (optional).
*/
public function __construct( array $groupDefinition ) {
$groupDefinition['isFullCoverage'] = true;
diff --git a/includes/changes/ChangesListFilter.php
b/includes/changes/ChangesListFilter.php
index 9af9adc..bd895bb 100644
--- a/includes/changes/ChangesListFilter.php
+++ b/includes/changes/ChangesListFilter.php
@@ -74,25 +74,25 @@
protected $description;
/**
- * List of conflicting groups
+ * Array of associative arrays with conflict information. See
+ * setUnidirectionalConflict
*
- * @var array $conflictingGroups Array of associative arrays with
conflict
- * information. See setUnidirectionalConflict
+ * @var array $conflictingGroups
*/
protected $conflictingGroups = [];
/**
- * List of conflicting filters
+ * Array of associative arrays with conflict information. See
+ * setUnidirectionalConflict
*
- * @var array $conflictingFilters Array of associative arrays with
conflict
- * information. See setUnidirectionalConflict
+ * @var array $conflictingFilters
*/
protected $conflictingFilters = [];
/**
- * List of filters that are a subset of the current filter
+ * Array of associative arrays with subset information
*
- * @var array $subsetFilters Array of associative arrays with subset
information
+ * @var array $subsetFilters
*/
protected $subsetFilters = [];
@@ -117,23 +117,22 @@
* UI it's for.
*
* @param array $filterDefinition ChangesListFilter definition
- *
- * $filterDefinition['name'] string Name of filter; use lowercase with
no
- * punctuation
- * $filterDefinition['cssClassSuffix'] string CSS class suffix, used to
mark
- * that a particular row belongs to this filter (when a row is
included by the
- * filter) (optional)
- * $filterDefinition['isRowApplicableCallable'] Callable taking two
parameters, the
- * IContextSource, and the RecentChange object for the row, and
returning true if
- * the row is attributed to this filter. The above CSS class will
then be
- * automatically added (optional, required if cssClassSuffix is used).
- * $filterDefinition['group'] ChangesListFilterGroup Group. Filter
group this
- * belongs to.
- * $filterDefinition['label'] string i18n key of label for structured
UI.
- * $filterDefinition['description'] string i18n key of description for
structured
- * UI.
- * $filterDefinition['priority'] int Priority integer. Higher value
means higher
- * up in the group's filter list.
+ * * $filterDefinition['name'] string Name of filter; use lowercase
with no
+ * punctuation
+ * * $filterDefinition['cssClassSuffix'] string CSS class suffix, used
to mark
+ * that a particular row belongs to this filter (when a row is
included by the
+ * filter) (optional)
+ * * $filterDefinition['isRowApplicableCallable'] Callable taking two
parameters, the
+ * IContextSource, and the RecentChange object for the row, and
returning true if
+ * the row is attributed to this filter. The above CSS class will
then be
+ * automatically added (optional, required if cssClassSuffix is
used).
+ * * $filterDefinition['group'] ChangesListFilterGroup Group. Filter
group this
+ * belongs to.
+ * * $filterDefinition['label'] string i18n key of label for structured
UI.
+ * * $filterDefinition['description'] string i18n key of description
for structured
+ * UI.
+ * * $filterDefinition['priority'] int Priority integer. Higher value
means higher
+ * up in the group's filter list.
*/
public function __construct( array $filterDefinition ) {
if ( isset( $filterDefinition['group'] ) ) {
@@ -251,7 +250,7 @@
* This means that anything in the results for the other filter is also
in the
* results for this one.
*
- * @param ChangesListFilter The filter the current instance is a
superset of
+ * @param ChangesListFilter $other The filter the current instance is a
superset of
*/
public function setAsSupersetOf( ChangesListFilter $other ) {
if ( $other->getGroup() !== $this->getGroup() ) {
@@ -346,7 +345,7 @@
*
* @param IContextSource $ctx Context source
* @param RecentChange $rc Recent changes object
- * @param Non-associative array of CSS class names; appended to if
needed
+ * @param array &$classes Non-associative array of CSS class names;
appended to if needed
*/
public function applyCssClassIfNeeded( IContextSource $ctx,
RecentChange $rc, array &$classes ) {
if ( $this->isRowApplicableCallable === null ) {
diff --git a/includes/changes/ChangesListFilterGroup.php
b/includes/changes/ChangesListFilterGroup.php
index 71c474a..1dc8a27 100644
--- a/includes/changes/ChangesListFilterGroup.php
+++ b/includes/changes/ChangesListFilterGroup.php
@@ -106,18 +106,18 @@
protected $isFullCoverage;
/**
- * List of conflicting groups
+ * Array of associative arrays with conflict information. See
+ * setUnidirectionalConflict
*
- * @var array $conflictingGroups Array of associative arrays with
conflict
- * information. See setUnidirectionalConflict
+ * @var array $conflictingGroups
*/
protected $conflictingGroups = [];
/**
- * List of conflicting filters
+ * Array of associative arrays with conflict information. See
+ * setUnidirectionalConflict
*
- * @var array $conflictingFilters Array of associative arrays with
conflict
- * information. See setUnidirectionalConflict
+ * @var array $conflictingFilters
*/
protected $conflictingFilters = [];
@@ -131,25 +131,25 @@
* @param array $groupDefinition Configuration of group
* * $groupDefinition['name'] string Group name; use camelCase with no
punctuation
* * $groupDefinition['title'] string i18n key for title (optional, can
be omitted
- * * only if none of the filters in the group display in the
structured UI)
+ * only if none of the filters in the group display in the
structured UI)
* * $groupDefinition['type'] string A type constant from a subclass of
this one
* * $groupDefinition['priority'] int Priority integer. Higher value
means higher
- * * up in the group list (optional, defaults to -100).
+ * up in the group list (optional, defaults to -100).
* * $groupDefinition['filters'] array Numeric array of filter
definitions, each of which
- * * is an associative array to be passed to the filter constructor.
However,
- * * 'priority' is optional for the filters. Any filter that has
priority unset
- * * will be put to the bottom, in the order given.
+ * is an associative array to be passed to the filter constructor.
However,
+ * 'priority' is optional for the filters. Any filter that has
priority unset
+ * will be put to the bottom, in the order given.
* * $groupDefinition['isFullCoverage'] bool Whether the group is full
coverage;
- * * if true, this means that checking every item in the group means no
- * * changes list entries are filtered out.
+ * if true, this means that checking every item in the group means
no
+ * changes list entries are filtered out.
* * $groupDefinition['whatsThisHeader'] string i18n key for header of
"What's
- * * This" popup (optional).
+ * This" popup (optional).
* * $groupDefinition['whatsThisBody'] string i18n key for body of
"What's This"
- * * popup (optional).
+ * popup (optional).
* * $groupDefinition['whatsThisUrl'] string URL for main link of
"What's This"
- * * popup (optional).
+ * popup (optional).
* * $groupDefinition['whatsThisLinkText'] string i18n key of text for
main link of
- * * "What's This" popup (optional).
+ * "What's This" popup (optional).
*/
public function __construct( array $groupDefinition ) {
if ( strpos( $groupDefinition['name'], self::RESERVED_NAME_CHAR
) !== false ) {
diff --git a/includes/changes/ChangesListStringOptionsFilterGroup.php
b/includes/changes/ChangesListStringOptionsFilterGroup.php
index 1abf637..86b4a8b 100644
--- a/includes/changes/ChangesListStringOptionsFilterGroup.php
+++ b/includes/changes/ChangesListStringOptionsFilterGroup.php
@@ -61,12 +61,6 @@
const NONE = '';
/**
- * Group name; used as form parameter.
- *
- * @var string $name
- */
-
- /**
* Defaul parameter value
*
* @var string $defaultValue
@@ -86,35 +80,35 @@
* @param array $groupDefinition Configuration of group
* * $groupDefinition['name'] string Group name
* * $groupDefinition['title'] string i18n key for title (optional, can
be omitted
- * * only if none of the filters in the group display in the
structured UI)
+ * only if none of the filters in the group display in the
structured UI)
* * $groupDefinition['priority'] int Priority integer. Higher means
higher in the
- * * group list.
+ * group list.
* * $groupDefinition['filters'] array Numeric array of filter
definitions, each of which
- * * is an associative array to be passed to the filter constructor.
However,
- * * 'priority' is optional for the filters. Any filter that has
priority unset
- * * will be put to the bottom, in the order given.
+ * is an associative array to be passed to the filter constructor.
However,
+ * 'priority' is optional for the filters. Any filter that has
priority unset
+ * will be put to the bottom, in the order given.
* * $groupDefinition['default'] string Default for group.
* * $groupDefinition['isFullCoverage'] bool Whether the group is full
coverage;
- * * if true, this means that checking every item in the group means no
- * * changes list entries are filtered out.
+ * if true, this means that checking every item in the group means
no
+ * changes list entries are filtered out.
* * $groupDefinition['queryCallable'] callable Callable accepting
parameters:
- * * string $specialPageClassName Class name of current special page
- * * IContextSource $context Context, for e.g. user
- * * IDatabase $dbr Database, for addQuotes, makeList, and similar
- * * array &$tables Array of tables; see IDatabase::select $table
- * * array &$fields Array of fields; see IDatabase::select $vars
- * * array &$conds Array of conditions; see IDatabase::select $conds
- * * array &$query_options Array of query options; see
IDatabase::select $options
- * * array &$join_conds Array of join conditions; see
IDatabase::select $join_conds
- * * array $selectedValues The allowed and requested values,
lower-cased and sorted
+ * * string $specialPageClassName Class name of current special
page
+ * * IContextSource $context Context, for e.g. user
+ * * IDatabase $dbr Database, for addQuotes, makeList, and similar
+ * * array &$tables Array of tables; see IDatabase::select $table
+ * * array &$fields Array of fields; see IDatabase::select $vars
+ * * array &$conds Array of conditions; see IDatabase::select
$conds
+ * * array &$query_options Array of query options; see
IDatabase::select $options
+ * * array &$join_conds Array of join conditions; see
IDatabase::select $join_conds
+ * * array $selectedValues The allowed and requested values,
lower-cased and sorted
* * $groupDefinition['whatsThisHeader'] string i18n key for header of
"What's
- * * This" popup (optional).
+ * This" popup (optional).
* * $groupDefinition['whatsThisBody'] string i18n key for body of
"What's This"
- * * popup (optional).
+ * popup (optional).
* * $groupDefinition['whatsThisUrl'] string URL for main link of
"What's This"
- * * popup (optional).
+ * popup (optional).
* * $groupDefinition['whatsThisLinkText'] string i18n key of text for
main link of
- * * "What's This" popup (optional).
+ * "What's This" popup (optional).
*/
public function __construct( array $groupDefinition ) {
if ( !isset( $groupDefinition['isFullCoverage'] ) ) {
diff --git a/includes/specialpage/ChangesListSpecialPage.php
b/includes/specialpage/ChangesListSpecialPage.php
index 9074d30..d527812 100644
--- a/includes/specialpage/ChangesListSpecialPage.php
+++ b/includes/specialpage/ChangesListSpecialPage.php
@@ -822,7 +822,7 @@
/**
* Get filter group definition from legacy custom filters
*
- * @param array Custom filters from legacy hooks
+ * @param array $customFilters Custom filters from legacy hooks
* @return array Group definition
*/
protected function getFilterGroupDefinitionFromLegacyCustomFilters(
$customFilters ) {
@@ -1343,6 +1343,8 @@
* @param array &$query_options Array of query options; see
IDatabase::select $options
* @param array &$join_conds Array of join conditions; see
IDatabase::select $join_conds
* @param array $selectedExpLevels The allowed active values, sorted
+ * @param int $now Number of seconds since the UNIX epoch, or 0 if not
given
+ * (optional)
*/
public function filterOnUserExperienceLevel( $specialPageClassName,
$context, $dbr,
&$tables, &$fields, &$conds, &$query_options, &$join_conds,
$selectedExpLevels, $now = 0 ) {
--
To view, visit https://gerrit.wikimedia.org/r/351570
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I7a8c95efaff7c844e32e4375dfe6af8c2e91923f
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Mattflaschen <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits