MediaWiki
REL1_23
|
TODO: Allow sorting by count. More...
Public Member Functions | |
__construct (IContextSource $context, $from, PageLinkRenderer $linkRenderer) | |
formatRow ($result) | |
Abstract formatting function. | |
getBody () | |
Get the formatted result list. | |
getDefaultQuery () | |
Get an array of query parameters that should be put into self-links. | |
getIndexField () | |
This function should be overridden to return the name of the index fi- eld. | |
getQueryInfo () | |
This function should be overridden to provide all parameters needed for the main paged query. | |
getStartForm ($from) | |
Protected Member Functions | |
getDefaultDirections () | |
Return the default sorting direction: false for ascending, true for descending. | |
Protected Attributes | |
PageLinkRenderer | $linkRenderer |
TODO: Allow sorting by count.
We need to have a unique index to do this properly.
Definition at line 101 of file SpecialCategories.php.
CategoryPager::__construct | ( | IContextSource $ | context, |
$ | from, | ||
PageLinkRenderer $ | linkRenderer | ||
) |
IContextSource | $context | |
string | $from | |
PageLinkRenderer | $linkRenderer |
Definition at line 112 of file SpecialCategories.php.
CategoryPager::formatRow | ( | $ | row | ) |
Abstract formatting function.
This should return an HTML string representing the result row $row. Rows will be concatenated and returned by getBody()
array | stdClass | $row | Database row |
Reimplemented from IndexPager.
Definition at line 171 of file SpecialCategories.php.
Get the formatted result list.
Calls getStartBody(), formatRow() and getEndBody(), concatenates the results and returns them.
Reimplemented from IndexPager.
Definition at line 157 of file SpecialCategories.php.
References $batch, as, and Title\makeTitleSafe().
CategoryPager::getDefaultDirections | ( | ) | [protected] |
Return the default sorting direction: false for ascending, true for descending.
You can also have an associative array of ordertype => dir, if multiple order types are supported. In this case getIndexField() must return an array, and the keys of that must exactly match the keys of this.
For backward compatibility, this method's return value will be ignored if $this->mDefaultDirection is already set when the constructor is called, for instance if it's statically initialized. In that case the value of that variable (which must be a boolean) will be used.
Note that despite its name, this does not return the value of the $this->mDefaultDirection member variable. That's the default for this particular instantiation, which is a single value. This is the set of all defaults for the class.
Reimplemented from IndexPager.
Definition at line 151 of file SpecialCategories.php.
Get an array of query parameters that should be put into self-links.
By default, all parameters passed in the URL are used, except for a short blacklist.
Reimplemented from IndexPager.
Definition at line 139 of file SpecialCategories.php.
This function should be overridden to return the name of the index fi- eld.
If the pager supports multiple orders, it may return an array of 'querykey' => 'indexfield' pairs, so that a request with &count=querykey will use indexfield to sort. In this case, the first returned key is the default.
Needless to say, it's really not a good idea to use a non-unique index for this! That won't page right.
Reimplemented from IndexPager.
Definition at line 134 of file SpecialCategories.php.
This function should be overridden to provide all parameters needed for the main paged query.
It returns an associative array with the following elements: tables => Table(s) for passing to Database::select() fields => Field(s) for passing to Database::select(), may be * conds => WHERE conditions options => option array join_conds => JOIN conditions
Reimplemented from IndexPager.
Definition at line 125 of file SpecialCategories.php.
CategoryPager::getStartForm | ( | $ | from | ) |
Definition at line 180 of file SpecialCategories.php.
PageLinkRenderer CategoryPager::$linkRenderer [protected] |
Definition at line 105 of file SpecialCategories.php.