MediaWiki  REL1_24
SpecialStatistics Class Reference

Special page lists various statistics, including the contents of `site_stats`, plus page view details if enabled. More...

Inheritance diagram for SpecialStatistics:
Collaboration diagram for SpecialStatistics:

List of all members.

Public Member Functions

 __construct ()
 execute ($par)
 Default execute method Checks user permissions.

Public Attributes

 $activeUsers = 0
 $edits
 $good
 $images
 $total
 $users

Protected Member Functions

 getGroupName ()
 Under which header this special page is listed in Special:SpecialPages See messages 'specialpages-group-*' for valid names This method defaults to group 'other'.

Private Member Functions

 formatRow ($text, $number, $trExtraParams=array(), $descMsg= '', $descMsgParam= '')
 Format a row.
 formatRowHeader ($header)
 Format row header.
 getEditStats ()
 getGroupStats ()
 getMostViewedPages ()
 getOtherStats (array $stats)
 Conversion of external statistics into an internal representation Following a ([<header-message>][<item-message>] = number) pattern.
 getPageStats ()
 Each of these methods is pretty self-explanatory, get a particular row for the table of statistics.
 getUserStats ()
 getViewsStats ()

Private Attributes

 $views

Detailed Description

Special page lists various statistics, including the contents of `site_stats`, plus page view details if enabled.

Definition at line 30 of file SpecialStatistics.php.


Constructor & Destructor Documentation

Definition at line 34 of file SpecialStatistics.php.


Member Function Documentation

SpecialStatistics::formatRow ( text,
number,
trExtraParams = array(),
descMsg = '',
descMsgParam = '' 
) [private]

Format a row.

Parameters:
string$textDescription of the row
float$numberA statistical number
array$trExtraParamsParams to table row, see Html::elememt
string$descMsgMessage key
array | string$descMsgParamMessage parameters
Returns:
string Table row in HTML format

Definition at line 119 of file SpecialStatistics.php.

References array(), Xml\element(), SpecialPage\msg(), and Html\rawElement().

Referenced by getEditStats(), getGroupStats(), getMostViewedPages(), getOtherStats(), getPageStats(), getUserStats(), and getViewsStats().

SpecialStatistics::formatRowHeader ( header) [private]

Format row header.

Parameters:
string$header
Returns:
string

Definition at line 348 of file SpecialStatistics.php.

References array(), Xml\closeElement(), SpecialPage\msg(), Xml\openElement(), and Xml\tags().

Referenced by getOtherStats().

Under which header this special page is listed in Special:SpecialPages See messages 'specialpages-group-*' for valid names This method defaults to group 'other'.

Returns:
string
Since:
1.21

Reimplemented from SpecialPage.

Definition at line 354 of file SpecialStatistics.php.

SpecialStatistics::getOtherStats ( array stats) [private]

Conversion of external statistics into an internal representation Following a ([<header-message>][<item-message>] = number) pattern.

Parameters:
array$stats
Returns:
string

Definition at line 304 of file SpecialStatistics.php.

References $key, $name, $value, array(), as, formatRow(), formatRowHeader(), SpecialPage\getLanguage(), and SpecialPage\msg().

Referenced by execute().

Each of these methods is pretty self-explanatory, get a particular row for the table of statistics.

Returns:
string

Definition at line 142 of file SpecialStatistics.php.

References array(), Xml\closeElement(), formatRow(), SpecialPage\getLanguage(), SpecialPage\getTitleFor(), Linker\linkKnown(), SpecialPage\msg(), Xml\openElement(), and Xml\tags().

Referenced by execute().


Member Data Documentation

SpecialStatistics::$activeUsers = 0

Definition at line 32 of file SpecialStatistics.php.

SpecialStatistics::$edits

Definition at line 31 of file SpecialStatistics.php.

SpecialStatistics::$good

Definition at line 31 of file SpecialStatistics.php.

SpecialStatistics::$images

Definition at line 31 of file SpecialStatistics.php.

SpecialStatistics::$total

Definition at line 31 of file SpecialStatistics.php.

SpecialStatistics::$users

Definition at line 31 of file SpecialStatistics.php.

SpecialStatistics::$views [private]

Definition at line 31 of file SpecialStatistics.php.


The documentation for this class was generated from the following file: