MediaWiki  master
SiteStatsUpdate Class Reference

Class for handling updates to the site_stats table. More...

Inheritance diagram for SiteStatsUpdate:
Collaboration diagram for SiteStatsUpdate:

Public Member Functions

static string [] __construct ( $views, $edits, $good, $pages=0, $users=0)
 
 doUpdate ()
 Perform the actual work. More...
 
 merge (MergeableUpdate $update)
 Merge this update with $update. More...
 

Static Public Member Functions

static cacheUpdate (IDatabase $dbw)
 
static factory (array $deltas)
 

Protected Attributes

int $articles = 0
 
int $edits = 0
 
int $images = 0
 
int $pages = 0
 
int $users = 0
 

Static Private Attributes

static string [] $counters
 Map of (table column => counter type) More...
 

Detailed Description

Class for handling updates to the site_stats table.

Definition at line 27 of file SiteStatsUpdate.php.

Constructor & Destructor Documentation

◆ __construct()

static string [] SiteStatsUpdate::__construct (   $views,
  $edits,
  $good,
  $pages = 0,
  $users = 0 
)

Definition at line 49 of file SiteStatsUpdate.php.

References $edits, $pages, $users, edits, and pages.

Member Function Documentation

◆ cacheUpdate()

static SiteStatsUpdate::cacheUpdate ( IDatabase  $dbw)
static

◆ doUpdate()

SiteStatsUpdate::doUpdate ( )

Perform the actual work.

Implements DeferrableUpdate.

Definition at line 86 of file SiteStatsUpdate.php.

References $fname, $services, $type, as, DB_MASTER, SiteStats\unload(), Wikimedia\Rdbms\IDatabase\update(), and use.

◆ factory()

◆ merge()

SiteStatsUpdate::merge ( MergeableUpdate  $update)

Merge this update with $update.

Parameters
MergeableUpdate$updateUpdate of the same class type

Implements MergeableUpdate.

Definition at line 56 of file SiteStatsUpdate.php.

References as.

Member Data Documentation

◆ $articles

int SiteStatsUpdate::$articles = 0
protected

Definition at line 33 of file SiteStatsUpdate.php.

◆ $counters

string [] SiteStatsUpdate::$counters
staticprivate
Initial value:
= [
'ss_total_edits' => 'edits'

Map of (table column => counter type)

Definition at line 40 of file SiteStatsUpdate.php.

◆ $edits

int SiteStatsUpdate::$edits = 0
protected

Definition at line 29 of file SiteStatsUpdate.php.

Referenced by __construct().

◆ $images

int SiteStatsUpdate::$images = 0
protected

Definition at line 37 of file SiteStatsUpdate.php.

◆ $pages

int SiteStatsUpdate::$pages = 0
protected

Definition at line 31 of file SiteStatsUpdate.php.

Referenced by __construct().

◆ $users

int SiteStatsUpdate::$users = 0
protected

Definition at line 35 of file SiteStatsUpdate.php.

Referenced by __construct().


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