MediaWiki
REL1_22
|
Public Member Functions | |
clear () | |
Deletes all sites from the database. | |
getSite ($globalId, $source= 'cache') | |
Returns the site with provided global id, or null if there is no such site. | |
getSites ($source= 'cache') | |
Returns a list of all sites. | |
saveSite (Site $site) | |
Saves the provided site. | |
saveSites (array $sites) | |
Saves the provided sites. |
Definition at line 29 of file SiteStore.php.
SiteStore::clear | ( | ) |
Deletes all sites from the database.
After calling clear(), getSites() will return an empty list and getSite() will return null until saveSite() or saveSites() is called.
Implemented in SiteSQLStore.
SiteStore::getSite | ( | $ | globalId, |
$ | source = 'cache' |
||
) |
Returns the site with provided global id, or null if there is no such site.
string | $globalId | |
string | $source | either 'cache' or 'recache'. If 'cache', the values are allowed (but not obliged) to come from a cache. |
Implemented in SiteSQLStore.
SiteStore::getSites | ( | $ | source = 'cache' | ) |
Returns a list of all sites.
By default this site is fetched from the cache, which can be changed to loading the list from the database using the $useCache parameter.
string | $source | either 'cache' or 'recache'. If 'cache', the values are allowed (but not obliged) to come from a cache. |
Implemented in SiteSQLStore.
SiteStore::saveSite | ( | Site $ | site | ) |
Saves the provided site.
Site | $site |
Implemented in SiteSQLStore.
SiteStore::saveSites | ( | array $ | sites | ) |
Saves the provided sites.
Site[] | $sites |
Implemented in SiteSQLStore.