MediaWiki REL1_41
DBSiteStore Class Reference

Holds a list of sites stored in the database. More...

Inherits SiteStore.

Collaboration diagram for DBSiteStore:

Public Member Functions

 __construct (IConnectionProvider $dbProvider)
 
 clear ()
 Clears the list of sites stored in the database.
 
 getSite ( $globalId)
 
 getSites ()
 
 reset ()
 Resets the SiteList.
 
 saveSite (Site $site)
 
 saveSites (array $sites)
 

Protected Member Functions

 loadSites ()
 Fetches the site from the database and loads them into the sites field.
 

Protected Attributes

SiteList null $sites = null
 

Detailed Description

Holds a list of sites stored in the database.

Since
1.25
Author
Jeroen De Dauw < jeroe.nosp@m.nded.nosp@m.auw@g.nosp@m.mail.nosp@m..com >
Daniel Kinzler

Definition at line 32 of file DBSiteStore.php.

Constructor & Destructor Documentation

◆ __construct()

DBSiteStore::__construct ( IConnectionProvider $dbProvider)
Since
1.27
Parameters
IConnectionProvider$dbProvider

Definition at line 42 of file DBSiteStore.php.

Member Function Documentation

◆ clear()

DBSiteStore::clear ( )

Clears the list of sites stored in the database.

See also
SiteStore::clear()

Implements SiteStore.

Definition at line 240 of file DBSiteStore.php.

References reset().

◆ getSite()

DBSiteStore::getSite ( $globalId)
See also
SiteStore::getSite
Since
1.25
Parameters
string$globalId
Returns
Site|null

Implements SiteLookup.

Definition at line 124 of file DBSiteStore.php.

References getSites().

◆ getSites()

DBSiteStore::getSites ( )
See also
SiteStore::getSites
Since
1.25
Returns
SiteList

Implements SiteLookup.

Definition at line 52 of file DBSiteStore.php.

References $sites, and loadSites().

Referenced by getSite().

◆ loadSites()

DBSiteStore::loadSites ( )
protected

Fetches the site from the database and loads them into the sites field.

Since
1.25

Definition at line 63 of file DBSiteStore.php.

References Site\newForType().

Referenced by getSites().

◆ reset()

DBSiteStore::reset ( )

Resets the SiteList.

Since
1.25

Definition at line 231 of file DBSiteStore.php.

Referenced by clear(), and saveSites().

◆ saveSite()

DBSiteStore::saveSite ( Site $site)
See also
SiteStore::saveSite
Since
1.25
Parameters
Site$site
Returns
bool Success indicator

Implements SiteStore.

Definition at line 139 of file DBSiteStore.php.

References saveSites().

◆ saveSites()

DBSiteStore::saveSites ( array $sites)
See also
SiteStore::saveSites
Since
1.25
Parameters
Site[]$sites
Returns
bool Success indicator

Implements SiteStore.

Definition at line 150 of file DBSiteStore.php.

References $sites, and reset().

Referenced by saveSite().

Member Data Documentation

◆ $sites

SiteList null DBSiteStore::$sites = null
protected

Definition at line 34 of file DBSiteStore.php.

Referenced by getSites(), and saveSites().


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