MediaWiki REL1_34
|
Public Member Functions | |
extractInfo ( $path, array $info, $version) | |
getExtraAutoloaderPaths ( $dir, array $info) | |
Get the path for additional autoloaders, e.g. | |
getExtractedInfo () | |
getRequirements (array $info, $includeDev) | |
Get the requirements for the provided info. | |
Protected Member Functions | |
extractAttributes ( $path, array $info) | |
extractConfig1 (array $info) | |
Set configuration settings for manifest_version == 1. | |
extractConfig2 (array $info, $dir) | |
Set configuration settings for manifest_version == 2. | |
extractCredits ( $path, array $info) | |
extractExtensionMessagesFiles ( $dir, array $info) | |
extractHooks (array $info) | |
extractMessagesDirs ( $dir, array $info) | |
Set message-related settings, which need to be expanded to use absolute paths. | |
extractNamespaces (array $info) | |
Register namespaces with the appropriate global settings. | |
extractPathBasedGlobal ( $global, $dir, $paths) | |
extractResourceLoaderModules ( $dir, array $info) | |
storeToArray ( $path, $name, $value, &$array) | |
Protected Attributes | |
array | $attributes = [] |
Any thing else in the $info that hasn't already been processed. | |
callable[] | $callbacks = [] |
Things to be called once registration of these extensions are done keyed by the name of the extension that it belongs to. | |
array | $config = [] |
array | $credits = [] |
array | $defines = [] |
Things that should be define()'d. | |
array | $extAttributes = [] |
Extension attributes, keyed by name => settings. | |
array | $globals |
Stuff that is going to be set to $GLOBALS. | |
Static Protected Attributes | |
static string[] | $coreAttributes |
Top-level attributes that come from MW core. | |
static array | $creditsAttributes |
Keys that are part of the extension credits. | |
static array | $globalSettings |
Keys that should be set to $GLOBALS. | |
static array | $mergeStrategies |
Mapping of global settings to their specific merge strategies. | |
static array | $notAttributes |
Things that are not 'attributes', and are not in $globalSettings or $creditsAttributes. | |
Private Member Functions | |
addConfigGlobal ( $key, $value, $extName) | |
Helper function to set a value to a specific global, if it isn't set already. | |
Definition at line 3 of file ExtensionProcessor.php.
|
private |
Helper function to set a value to a specific global, if it isn't set already.
string | $key | The config key with the prefix and anything |
mixed | $value | The value of the config |
string | $extName | Name of the extension |
Definition at line 602 of file ExtensionProcessor.php.
Referenced by extractConfig1(), and extractConfig2().
|
protected |
string | $path | |
array | $info |
Definition at line 267 of file ExtensionProcessor.php.
References $path, and storeToArray().
Referenced by extractInfo().
|
protected |
Set configuration settings for manifest_version == 1.
array | $info |
Definition at line 551 of file ExtensionProcessor.php.
References addConfigGlobal().
Referenced by extractInfo().
|
protected |
Set configuration settings for manifest_version == 2.
array | $info | |
string | $dir |
Definition at line 574 of file ExtensionProcessor.php.
References addConfigGlobal().
Referenced by extractInfo().
|
protected |
string | $path | |
array | $info |
Exception |
Definition at line 518 of file ExtensionProcessor.php.
References $credits, and $path.
Referenced by extractInfo().
|
protected |
Definition at line 486 of file ExtensionProcessor.php.
References $file.
Referenced by extractInfo().
|
protected |
Definition at line 381 of file ExtensionProcessor.php.
Referenced by extractInfo().
ExtensionProcessor::extractInfo | ( | $path, | |
array | $info, | ||
$version ) |
string | $path | |
array | $info | |
int | $version | manifest_version for info |
Implements Processor.
Definition at line 195 of file ExtensionProcessor.php.
References $path, extractAttributes(), extractConfig1(), extractConfig2(), extractCredits(), extractExtensionMessagesFiles(), extractHooks(), extractMessagesDirs(), extractNamespaces(), extractPathBasedGlobal(), extractResourceLoaderModules(), and storeToArray().
|
protected |
Set message-related settings, which need to be expanded to use absolute paths.
string | $dir | |
array | $info |
Definition at line 502 of file ExtensionProcessor.php.
References $file.
Referenced by extractInfo().
|
protected |
Register namespaces with the appropriate global settings.
array | $info |
Definition at line 400 of file ExtensionProcessor.php.
Referenced by extractInfo().
|
protected |
Definition at line 611 of file ExtensionProcessor.php.
References $path.
Referenced by extractInfo().
|
protected |
Definition at line 438 of file ExtensionProcessor.php.
Referenced by extractInfo().
ExtensionProcessor::getExtraAutoloaderPaths | ( | $dir, | |
array | $info ) |
Get the path for additional autoloaders, e.g.
the one of Composer.
string | $dir | |
array | $info |
Implements Processor.
Definition at line 635 of file ExtensionProcessor.php.
ExtensionProcessor::getExtractedInfo | ( | ) |
Implements Processor.
Definition at line 275 of file ExtensionProcessor.php.
References $attributes, $callbacks, $config, $credits, $defines, $globals, and storeToArray().
ExtensionProcessor::getRequirements | ( | array | $info, |
$includeDev ) |
Get the requirements for the provided info.
array | $info | |
bool | $includeDev |
Implements Processor.
Definition at line 309 of file ExtensionProcessor.php.
|
protected |
string | $path | |
string | $name | |
array | $value | |
array | &$array |
InvalidArgumentException |
Definition at line 624 of file ExtensionProcessor.php.
Referenced by extractAttributes(), extractInfo(), and getExtractedInfo().
|
protected |
Any thing else in the $info that hasn't already been processed.
Definition at line 180 of file ExtensionProcessor.php.
Referenced by getExtractedInfo().
|
protected |
Things to be called once registration of these extensions are done keyed by the name of the extension that it belongs to.
Definition at line 162 of file ExtensionProcessor.php.
Referenced by getExtractedInfo().
|
protected |
Definition at line 172 of file ExtensionProcessor.php.
Referenced by getExtractedInfo().
|
staticprotected |
Top-level attributes that come from MW core.
Definition at line 65 of file ExtensionProcessor.php.
|
protected |
Definition at line 167 of file ExtensionProcessor.php.
Referenced by extractCredits(), and getExtractedInfo().
|
staticprotected |
Keys that are part of the extension credits.
Definition at line 99 of file ExtensionProcessor.php.
|
protected |
Things that should be define()'d.
Definition at line 154 of file ExtensionProcessor.php.
Referenced by getExtractedInfo().
|
protected |
Extension attributes, keyed by name => settings.
Definition at line 188 of file ExtensionProcessor.php.
|
protected |
Stuff that is going to be set to $GLOBALS.
Some keys are pre-set to arrays so we can += to them
Definition at line 144 of file ExtensionProcessor.php.
Referenced by getExtractedInfo().
|
staticprotected |
Keys that should be set to $GLOBALS.
Definition at line 10 of file ExtensionProcessor.php.
|
staticprotected |
Mapping of global settings to their specific merge strategies.
Definition at line 78 of file ExtensionProcessor.php.
|
staticprotected |
Things that are not 'attributes', and are not in $globalSettings or $creditsAttributes.
Definition at line 116 of file ExtensionProcessor.php.