MediaWiki REL1_31
InstallerOverrides.php
Go to the documentation of this file.
1<?php
27 private static function getOverrides() {
28 global $IP;
29 static $overrides;
30
31 if ( !$overrides ) {
32 $overrides = [
33 'LocalSettingsGenerator' => LocalSettingsGenerator::class,
34 'WebInstaller' => WebInstaller::class,
35 'CliInstaller' => CliInstaller::class,
36 ];
37 foreach ( glob( "$IP/mw-config/overrides/*.php" ) as $file ) {
38 require $file;
39 }
40 }
41
42 return $overrides;
43 }
44
50 public static function getLocalSettingsGenerator( Installer $installer ) {
51 $className = self::getOverrides()['LocalSettingsGenerator'];
52 return new $className( $installer );
53 }
54
60 public static function getWebInstaller( WebRequest $request ) {
61 $className = self::getOverrides()['WebInstaller'];
62 return new $className( $request );
63 }
64
72 public static function getCliInstaller( $siteName, $admin = null, array $options = [] ) {
73 $className = self::getOverrides()['CliInstaller'];
74 return new $className( $siteName, $admin, $options );
75 }
76}
static getCliInstaller( $siteName, $admin=null, array $options=[])
Instantiates and returns an instance of CliInstaller or its descendant classes.
static getWebInstaller(WebRequest $request)
Instantiates and returns an instance of WebInstaller or its descendant classes.
static getLocalSettingsGenerator(Installer $installer)
Instantiates and returns an instance of LocalSettingsGenerator or its descendant classes.
Base installer class.
Definition Installer.php:46
The WebRequest class encapsulates getting at data passed in the URL or via a POSTed form stripping il...
do that in ParserLimitReportFormat instead use this to modify the parameters of the image all existing parser cache entries will be invalid To avoid you ll need to handle that somehow(e.g. with the RejectParserCacheValue hook) because MediaWiki won 't do it for you. & $defaults also a ContextSource after deleting those rows but within the same transaction you ll probably need to make sure the header is varied on $request
Definition hooks.txt:2806
null means default in associative array with keys and values unescaped Should be merged with default with a value of false meaning to suppress the attribute in associative array with keys and values unescaped & $options
Definition hooks.txt:2001
$IP
Definition update.php:3