MediaWiki  REL1_19
ViewCountUpdate Class Reference

Update for the 'page_counter' field, when $wgDisableCounters is false. More...

Inheritance diagram for ViewCountUpdate:
Collaboration diagram for ViewCountUpdate:

List of all members.

Public Member Functions

 __construct ($id)
 Constructor.
 doUpdate ()
 Run the update.

Protected Member Functions

 collect ()

Protected Attributes

 $id

Detailed Description

Update for the 'page_counter' field, when $wgDisableCounters is false.

Depending on $wgHitcounterUpdateFreq, this will directly increment the 'page_counter' field or use the 'hitcounter' table and then collect the data from that table to update the 'page_counter' field in a batch operation.

Definition at line 30 of file ViewCountUpdate.php.


Constructor & Destructor Documentation

Constructor.

Parameters:
$idInteger: page ID to increment the view count

Definition at line 38 of file ViewCountUpdate.php.

References $id.


Member Function Documentation

ViewCountUpdate::collect ( ) [protected]

Definition at line 69 of file ViewCountUpdate.php.

References $res, $wgHitcounterUpdateFreq, wfGetDB(), wfProfileIn(), and wfProfileOut().

Referenced by doUpdate().

Here is the call graph for this function:

Here is the caller graph for this function:

Run the update.

Implements DeferrableUpdate.

Definition at line 45 of file ViewCountUpdate.php.

References $wgHitcounterUpdateFreq, collect(), and wfGetDB().

Here is the call graph for this function:


Member Data Documentation

ViewCountUpdate::$id [protected]

Definition at line 31 of file ViewCountUpdate.php.

Referenced by __construct().


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