MediaWiki
1.30.0
|
Abstraction for ResourceLoader modules, with name registration and maxage functionality. More...
Public Member Functions | |
getConfig () | |
getDefinitionMtime (ResourceLoaderContext $context) | |
Back-compat dummy for old subclass implementations of getModifiedTime(). More... | |
getDefinitionSummary (ResourceLoaderContext $context) | |
Get a list of resources that web browsers may preload. More... | |
getDependencies (ResourceLoaderContext $context=null) | |
Get a list of modules this module depends on. More... | |
getFlip ( $context) | |
getGroup () | |
Get the group this module is in. More... | |
getHashMtime (ResourceLoaderContext $context) | |
Back-compat dummy for old subclass implementations of getModifiedTime(). More... | |
getHeaders (ResourceLoaderContext $context) | |
Get headers to send as part of a module web response. More... | |
getMessages () | |
Get the messages needed for this module. More... | |
getModifiedHash (ResourceLoaderContext $context) | |
Helper method for providing a version hash to getVersionHash(). More... | |
getModifiedTime (ResourceLoaderContext $context) | |
Get this module's last modification timestamp for a given context. More... | |
getName () | |
Get this module's name. More... | |
getOrigin () | |
Get this module's origin. More... | |
getPosition () | |
From where in the page HTML should this module be loaded? More... | |
getScript (ResourceLoaderContext $context) | |
Get all JS for this module for a given language and skin. More... | |
getScriptURLsForDebug (ResourceLoaderContext $context) | |
Get the URL or URLs to load for this module's JS in debug mode. More... | |
getSkipFunction () | |
Get the skip function. More... | |
getSource () | |
Get the origin of this module. More... | |
getStyles (ResourceLoaderContext $context) | |
Get all CSS for this module for a given skin. More... | |
getStyleURLsForDebug (ResourceLoaderContext $context) | |
Get the URL or URLs to load for this module's CSS in debug mode. More... | |
getTargets () | |
Get target(s) for the module, eg ['desktop'] or ['desktop', 'mobile']. More... | |
getTemplates () | |
Takes named templates by the module and returns an array mapping. More... | |
getType () | |
Get the module's load type. More... | |
isKnownEmpty (ResourceLoaderContext $context) | |
Check whether this module is known to be empty. More... | |
isRaw () | |
Whether this module's JS expects to work without the client-side ResourceLoader module. More... | |
setConfig (Config $config) | |
setFileDependencies (ResourceLoaderContext $context, $files) | |
Set in-object cache for file dependencies. More... | |
setLogger (LoggerInterface $logger) | |
setMessageBlob ( $blob, $lang) | |
Set in-object cache for message blobs. More... | |
setName ( $name) | |
Set this module's name. More... | |
shouldEmbedModule (ResourceLoaderContext $context) | |
Check whether this module should be embeded rather than linked. More... | |
supportsURLLoading () | |
Whether this module supports URL loading. More... | |
Static Public Member Functions | |
static | expandRelativePaths (array $filePaths) |
Expand directories relative to $IP. More... | |
static | getRelativePaths (array $filePaths) |
Make file paths relative to MediaWiki directory. More... | |
Public Attributes | |
const | LOAD_GENERAL = 'general' |
const | LOAD_STYLES = 'styles' |
const | ORIGIN_ALL = 10 |
const | ORIGIN_CORE_INDIVIDUAL = 2 |
const | ORIGIN_CORE_SITEWIDE = 1 |
const | ORIGIN_USER_INDIVIDUAL = 4 |
const | ORIGIN_USER_SITEWIDE = 3 |
const | TYPE_COMBINED = 'combined' |
const | TYPE_SCRIPTS = 'scripts' |
const | TYPE_STYLES = 'styles' |
Protected Member Functions | |
getDeprecationInformation () | |
Get JS representing deprecation information for the current module if available. More... | |
getFileDependencies (ResourceLoaderContext $context) | |
Get the files this module depends on indirectly for a given skin. More... | |
getLogger () | |
getMessageBlob (ResourceLoaderContext $context) | |
Get the hash of the message blob. More... | |
saveFileDependencies (ResourceLoaderContext $context, $localFileRefs) | |
Set the files this module depends on indirectly for a given skin. More... | |
validateScriptFile ( $fileName, $contents) | |
Validate a given script file; if valid returns the original source. More... | |
Static Protected Member Functions | |
static | javaScriptParser () |
static | safeFileHash ( $filePath) |
Compute a non-cryptographic string hash of a file's contents. More... | |
static | safeFilemtime ( $filePath) |
Safe version of filemtime(), which doesn't throw a PHP warning if the file doesn't exist. More... | |
Protected Attributes | |
Config | $config |
$contents = [] | |
array bool | $deprecated = false |
$fileDeps = [] | |
LoggerInterface | $logger |
$msgBlobs = [] | |
$name = null | |
$origin = self::ORIGIN_CORE_SITEWIDE | |
$targets = [ 'desktop' ] | |
$versionHash = [] | |
Static Private Attributes | |
static JSParser | $jsParser |
Lazy-initialized; use self::javaScriptParser() More... | |
static | $parseCacheVersion = 1 |
Abstraction for ResourceLoader modules, with name registration and maxage functionality.
Definition at line 34 of file ResourceLoaderModule.php.
|
static |
Expand directories relative to $IP.
array | $filePaths |
Definition at line 545 of file ResourceLoaderModule.php.
References $IP, $path, global, and use.
Referenced by getFileDependencies().
ResourceLoaderModule::getConfig | ( | ) |
Definition at line 188 of file ResourceLoaderModule.php.
References $config.
Referenced by ResourceLoaderStartUpModule\getConfigSettings(), ResourceLoaderSkinModule\getDefinitionSummary(), ResourceLoaderStartUpModule\getDefinitionSummary(), getDefinitionSummary(), ResourceLoaderStartUpModule\getModuleRegistrations(), ResourceLoaderUserModule\getPages(), ResourceLoaderUserStylesModule\getPages(), ResourceLoaderSiteModule\getPages(), ResourceLoaderSiteStylesModule\getPages(), ResourceLoaderWikiModule\getPages(), ResourceLoaderJqueryMsgModule\getScript(), ResourceLoaderMediaWikiUtilModule\getScript(), ResourceLoaderStartUpModule\getScript(), ResourceLoaderFileModule\getScriptURLsForDebug(), ResourceLoaderFileModule\getSkipFunction(), ResourceLoaderSkinModule\getStyles(), ResourceLoaderWikiModule\getStyles(), ResourceLoaderFileModule\getStyleURLsForDebug(), ResourceLoaderFileModule\readScriptFiles(), and validateScriptFile().
ResourceLoaderModule::getDefinitionMtime | ( | ResourceLoaderContext | $context | ) |
Back-compat dummy for old subclass implementations of getModifiedTime().
ResourceLoaderContext | $context |
Definition at line 980 of file ResourceLoaderModule.php.
References getDefinitionSummary().
ResourceLoaderModule::getDefinitionSummary | ( | ResourceLoaderContext | $context | ) |
Get a list of resources that web browsers may preload.
Behaviour of rel=preload link is specified at https://www.w3.org/TR/preload/.
Use case for ResourceLoader originally part of T164299.
Return an array containing values from all significant properties of this module's definition.
Be careful not to normalise too much. Especially preserve the order of things that carry significance in getScript and getStyles (T39812).
Avoid including things that are insiginificant (e.g. order of message keys is insignificant and should be sorted to avoid unnecessary cache invalidation).
This data structure must exclusively contain arrays and scalars as values (avoid object instances) to allow simple serialisation using json_encode.
If modules have a hash or timestamp from another source, that may be incuded as-is.
A number of utility methods are available to help you gather data. These are not called by default and must be included by the subclass' getDefinitionSummary().
ResourceLoaderContext | $context |
Reimplemented in ResourceLoaderFileModule, ResourceLoaderImageModule, ResourceLoaderStartUpModule, ResourceLoaderWikiModule, ResourceLoaderSkinModule, and CiteDataModule.
Definition at line 924 of file ResourceLoaderModule.php.
References class, and getConfig().
Referenced by getDefinitionMtime().
ResourceLoaderModule::getDependencies | ( | ResourceLoaderContext | $context = null | ) |
Get a list of modules this module depends on.
Dependency information is taken into account when loading a module on the client side.
Note: It is expected that $context will be made non-optional in the near future.
ResourceLoaderContext | $context |
Reimplemented in ResourceLoaderFileModule, ResourceLoaderTestModule, ResourceLoaderUserModule, ResourceLoaderLanguageDataModule, GadgetResourceLoaderModule, ResourceLoaderSpecialCharacterDataModule, ResourceLoaderLanguageNamesModule, CiteDataModule, ResourceLoaderSiteModule, ResourceLoaderUserOptionsModule, and ResourceLoaderForeignApiModule.
Definition at line 366 of file ResourceLoaderModule.php.
|
protected |
Get JS representing deprecation information for the current module if available.
Definition at line 145 of file ResourceLoaderModule.php.
References $deprecated, $name, Xml\encodeJsCall(), and getName().
Referenced by ResourceLoaderFileModule\getScript().
|
protected |
Get the files this module depends on indirectly for a given skin.
These are only image files referenced by the module's stylesheet.
ResourceLoaderContext | $context |
Definition at line 416 of file ResourceLoaderModule.php.
References $context, $dbr, array(), DB_REPLICA, FormatJson\decode(), expandRelativePaths(), getName(), and wfGetDB().
Referenced by ResourceLoaderFileModule\getFileHashes(), and saveFileDependencies().
ResourceLoaderModule::getFlip | ( | $context | ) |
ResourceLoaderContext | $context |
Reimplemented in ResourceLoaderFileModule.
Definition at line 134 of file ResourceLoaderModule.php.
References $context, $wgContLang, and global.
Referenced by ResourceLoaderWikiModule\getStyles().
ResourceLoaderModule::getGroup | ( | ) |
Get the group this module is in.
Reimplemented in ResourceLoaderStartUpModule, ResourceLoaderFileModule, ResourceLoaderWikiModule, ResourceLoaderTestModule, GadgetResourceLoaderModule, ResourceLoaderUserStylesModule, ResourceLoaderUserTokensModule, ResourceLoaderUserModule, ResourceLoaderUserOptionsModule, and ResourceLoaderSiteStylesModule.
Definition at line 318 of file ResourceLoaderModule.php.
Referenced by shouldEmbedModule().
ResourceLoaderModule::getHashMtime | ( | ResourceLoaderContext | $context | ) |
Back-compat dummy for old subclass implementations of getModifiedTime().
This method used to use ObjectCache to track when a hash was first seen. That principle stems from a time that ResourceLoader could only identify module versions by timestamp. That is no longer the case. Use getDefinitionSummary() directly.
ResourceLoaderContext | $context |
Definition at line 964 of file ResourceLoaderModule.php.
References getModifiedHash().
|
final |
Get headers to send as part of a module web response.
It is not supported to send headers through this method that are required to be unique or otherwise sent once in an HTTP response because clients may make batch requests for multiple modules (as is the default behaviour for ResourceLoader clients).
For exclusive or aggregated headers, see ResourceLoader::sendResponseHeaders().
ResourceLoaderContext | $context |
Definition at line 603 of file ResourceLoaderModule.php.
|
protected |
Definition at line 218 of file ResourceLoaderModule.php.
References $logger.
Referenced by getMessageBlob().
|
protected |
Get the hash of the message blob.
ResourceLoaderContext | $context |
Definition at line 559 of file ResourceLoaderModule.php.
References $context, $lang, ResourceLoaderContext\getLanguage(), getLogger(), getMessages(), and getName().
Referenced by ResourceLoaderFileModule\getDefinitionSummary().
ResourceLoaderModule::getMessages | ( | ) |
Get the messages needed for this module.
To get a JSON blob with messages, use MessageBlobStore::get()
Reimplemented in ResourceLoaderFileModule, ResourceLoaderTestModule, GadgetResourceLoaderModule, and ResourceLoaderSpecialCharacterDataModule.
Definition at line 308 of file ResourceLoaderModule.php.
Referenced by MessageBlobStore\generateMessageBlob(), getMessageBlob(), and MessageBlobStore\makeCacheKey().
ResourceLoaderModule::getModifiedHash | ( | ResourceLoaderContext | $context | ) |
Helper method for providing a version hash to getVersionHash().
ResourceLoaderContext | $context |
Definition at line 949 of file ResourceLoaderModule.php.
Referenced by getHashMtime().
ResourceLoaderModule::getModifiedTime | ( | ResourceLoaderContext | $context | ) |
Get this module's last modification timestamp for a given context.
ResourceLoaderContext | $context | Context object |
Definition at line 938 of file ResourceLoaderModule.php.
ResourceLoaderModule::getName | ( | ) |
Get this module's name.
This is set when the module is registered with ResourceLoader::register()
Definition at line 105 of file ResourceLoaderModule.php.
References $name.
Referenced by MessageBlobStore\generateMessageBlob(), MessageBlobStore\getBlob(), getDeprecationInformation(), getFileDependencies(), ResourceLoaderImageModule\getImages(), getMessageBlob(), getScriptURLsForDebug(), getStyleURLsForDebug(), MessageBlobStore\makeCacheKey(), and saveFileDependencies().
ResourceLoaderModule::getOrigin | ( | ) |
Get this module's origin.
This is set when the module is registered with ResourceLoader::register()
Definition at line 126 of file ResourceLoaderModule.php.
References $origin.
Referenced by OutputPage\filterModules().
ResourceLoaderModule::getPosition | ( | ) |
From where in the page HTML should this module be loaded?
<head>
. Reimplemented in ResourceLoaderTestModule.
Definition at line 339 of file ResourceLoaderModule.php.
|
static |
Make file paths relative to MediaWiki directory.
This is used to make file paths safe for storing in a database without the paths becoming stale or incorrect when MediaWiki is moved or upgraded (T111481).
array | $filePaths |
Definition at line 531 of file ResourceLoaderModule.php.
References $IP, $path, global, and use.
Referenced by saveFileDependencies().
ResourceLoaderModule::getScript | ( | ResourceLoaderContext | $context | ) |
Get all JS for this module for a given language and skin.
Includes all relevant JS except loader scripts.
ResourceLoaderContext | $context |
Reimplemented in ResourceLoaderStartUpModule, ResourceLoaderFileModule, ResourceLoaderWikiModule, ResourceLoaderTestModule, ResourceLoaderUserTokensModule, ResourceLoaderLanguageDataModule, ResourceLoaderUserOptionsModule, ResourceLoaderLanguageNamesModule, ResourceLoaderSpecialCharacterDataModule, ResourceLoaderRawFileModule, ResourceLoaderUserDefaultsModule, ResourceLoaderUploadDialogModule, ResourceLoaderJqueryMsgModule, ResourceLoaderMediaWikiUtilModule, ResourceLoaderSyntaxHighlightVisualEditorModule, and CiteDataModule.
Definition at line 169 of file ResourceLoaderModule.php.
ResourceLoaderModule::getScriptURLsForDebug | ( | ResourceLoaderContext | $context | ) |
Get the URL or URLs to load for this module's JS in debug mode.
The default behavior is to return a load.php?only=scripts URL for the module, but file-based modules will want to override this to load the files directly.
This function is called only when 1) we're in debug mode, 2) there is no only= parameter and 3) supportsURLLoading() returns true. #2 is important to prevent an infinite loop, therefore this function MUST return either an only= URL or a non-load.php URL.
ResourceLoaderContext | $context |
Reimplemented in ResourceLoaderFileModule, ResourceLoaderJqueryMsgModule, and ResourceLoaderSyntaxHighlightVisualEditorModule.
Definition at line 239 of file ResourceLoaderModule.php.
References $context, $resourceLoader, getName(), and getSource().
Referenced by ResourceLoaderSyntaxHighlightVisualEditorModule\getScriptURLsForDebug(), and ResourceLoaderJqueryMsgModule\getScriptURLsForDebug().
ResourceLoaderModule::getSkipFunction | ( | ) |
Get the skip function.
Modules that provide fallback functionality can provide a "skip function". This function, if provided, will be passed along to the module registry on the client. When this module is loaded (either directly or as a dependency of another module), then this function is executed first. If the function returns true, the module will instantly be considered "ready" without requesting the associated module resources.
The value returned here must be valid javascript for execution in a private function. It must not contain the "function () {" and "}" wrapper though.
Reimplemented in ResourceLoaderFileModule, and ResourceLoaderTestModule.
Definition at line 404 of file ResourceLoaderModule.php.
ResourceLoaderModule::getSource | ( | ) |
Get the origin of this module.
Should only be overridden for foreign modules.
Reimplemented in ResourceLoaderTestModule.
Definition at line 328 of file ResourceLoaderModule.php.
Referenced by getScriptURLsForDebug(), ResourceLoaderImageModule\getStyles(), and getStyleURLsForDebug().
ResourceLoaderModule::getStyles | ( | ResourceLoaderContext | $context | ) |
Get all CSS for this module for a given skin.
ResourceLoaderContext | $context |
Reimplemented in ResourceLoaderFileModule, ResourceLoaderImageModule, ResourceLoaderWikiModule, ResourceLoaderTestModule, and ResourceLoaderSkinModule.
Definition at line 272 of file ResourceLoaderModule.php.
ResourceLoaderModule::getStyleURLsForDebug | ( | ResourceLoaderContext | $context | ) |
Get the URL or URLs to load for this module's CSS in debug mode.
The default behavior is to return a load.php?only=styles URL for the module, but file-based modules will want to override this to load the files directly. See also getScriptURLsForDebug()
ResourceLoaderContext | $context |
Reimplemented in ResourceLoaderFileModule.
Definition at line 286 of file ResourceLoaderModule.php.
References $context, $resourceLoader, getName(), and getSource().
ResourceLoaderModule::getTargets | ( | ) |
Get target(s) for the module, eg ['desktop'] or ['desktop', 'mobile'].
Reimplemented in ResourceLoaderFileModule, and GadgetResourceLoaderModule.
Definition at line 376 of file ResourceLoaderModule.php.
References $targets.
ResourceLoaderModule::getTemplates | ( | ) |
Takes named templates by the module and returns an array mapping.
Reimplemented in ResourceLoaderFileModule.
Definition at line 179 of file ResourceLoaderModule.php.
ResourceLoaderModule::getType | ( | ) |
Get the module's load type.
Reimplemented in ResourceLoaderFileModule, ResourceLoaderImageModule, ResourceLoaderWikiModule, ResourceLoaderTestModule, GadgetResourceLoaderModule, ResourceLoaderUserStylesModule, and ResourceLoaderSiteStylesModule.
Definition at line 386 of file ResourceLoaderModule.php.
References LOAD_GENERAL.
ResourceLoaderModule::isKnownEmpty | ( | ResourceLoaderContext | $context | ) |
Check whether this module is known to be empty.
If a child class has an easy and cheap way to determine that this module is definitely going to be empty, it should override this method to return true in that case. Callers may optimize the request for this module away if this function returns true.
ResourceLoaderContext | $context |
Reimplemented in ResourceLoaderWikiModule, ResourceLoaderTestModule, and ResourceLoaderSkinModule.
Definition at line 997 of file ResourceLoaderModule.php.
ResourceLoaderModule::isRaw | ( | ) |
Whether this module's JS expects to work without the client-side ResourceLoader module.
Returning true from this function will prevent mw.loader.state() call from being appended to the bottom of the script.
Reimplemented in ResourceLoaderFileModule, ResourceLoaderStartUpModule, and ResourceLoaderTestModule.
Definition at line 350 of file ResourceLoaderModule.php.
|
staticprotected |
Definition at line 1060 of file ResourceLoaderModule.php.
References $jsParser.
Referenced by validateScriptFile().
|
staticprotected |
Compute a non-cryptographic string hash of a file's contents.
If the file does not exist or cannot be read, returns an empty string.
string | $filePath | File path |
Definition at line 1089 of file ResourceLoaderModule.php.
References FileContentsHasher\getFileContentsHash().
|
staticprotected |
Safe version of filemtime(), which doesn't throw a PHP warning if the file doesn't exist.
Defaults to 1.
string | $filePath | File path |
Definition at line 1074 of file ResourceLoaderModule.php.
|
protected |
Set the files this module depends on indirectly for a given skin.
ResourceLoaderContext | $context | |
array | $localFileRefs | List of files |
Definition at line 463 of file ResourceLoaderModule.php.
References $cache, $context, $e, DB_MASTER, FormatJson\encode(), getFileDependencies(), ObjectCache\getLocalClusterInstance(), getName(), getRelativePaths(), use, wfDebugLog(), and wfGetDB().
Referenced by ResourceLoaderFileModule\getStyles().
ResourceLoaderModule::setConfig | ( | Config | $config | ) |
Config | $config |
Definition at line 201 of file ResourceLoaderModule.php.
References $config.
ResourceLoaderModule::setFileDependencies | ( | ResourceLoaderContext | $context, |
$files | |||
) |
Set in-object cache for file dependencies.
This is used to retrieve data in batches. See ResourceLoader::preloadModuleInfo(). To save the data, use saveFileDependencies().
ResourceLoaderContext | $context | |
string[] | $files | Array of file names |
Definition at line 451 of file ResourceLoaderModule.php.
References $context.
ResourceLoaderModule::setLogger | ( | LoggerInterface | $logger | ) |
LoggerInterface | $logger |
Definition at line 210 of file ResourceLoaderModule.php.
References $logger.
ResourceLoaderModule::setMessageBlob | ( | $blob, | |
$lang | |||
) |
Set in-object cache for message blobs.
Used to allow fetching of message blobs in batches. See ResourceLoader::preloadModuleInfo().
string | null | $blob | JSON blob or null |
string | $lang | Language code |
Definition at line 585 of file ResourceLoaderModule.php.
ResourceLoaderModule::setName | ( | $name | ) |
Set this module's name.
This is called by ResourceLoader::register() when registering the module. Other code should not call this.
string | $name | Name |
Definition at line 115 of file ResourceLoaderModule.php.
ResourceLoaderModule::shouldEmbedModule | ( | ResourceLoaderContext | $context | ) |
Check whether this module should be embeded rather than linked.
Modules returning true here will be embedded rather than loaded by ResourceLoaderClientHtml.
ResourceLoaderContext | $context |
Reimplemented in ResourceLoaderTestModule.
Definition at line 1011 of file ResourceLoaderModule.php.
References getGroup().
ResourceLoaderModule::supportsURLLoading | ( | ) |
Whether this module supports URL loading.
If this function returns false, getScript() will be used even in cases (debug mode, no only param) where getScriptURLsForDebug() would normally be used instead.
Reimplemented in ResourceLoaderImageModule, ResourceLoaderStartUpModule, ResourceLoaderFileModule, ResourceLoaderUserTokensModule, ResourceLoaderUserOptionsModule, and ResourceLoaderMediaWikiUtilModule.
Definition at line 260 of file ResourceLoaderModule.php.
|
protected |
Validate a given script file; if valid returns the original source.
If invalid, returns replacement JS source that throws an exception.
string | $fileName | |
string | $contents |
Definition at line 1027 of file ResourceLoaderModule.php.
References $cache, $contents, $e, $parser, Xml\encodeJsVar(), getConfig(), ObjectCache\getMainWANInstance(), javaScriptParser(), and use.
Referenced by ResourceLoaderTestModule\getScript(), ResourceLoaderWikiModule\getScript(), ResourceLoaderFileModule\getSkipFunction(), and ResourceLoaderFileModule\readScriptFiles().
|
protected |
Definition at line 85 of file ResourceLoaderModule.php.
Referenced by getConfig(), ResourceLoaderImageModule\getGlobalVariants(), ResourceLoaderUserModule\getPages(), ResourceLoaderUserStylesModule\getPages(), ResourceLoaderWikiModule\getPages(), ResourceLoaderUploadDialogModule\getScript(), and setConfig().
|
protected |
Definition at line 80 of file ResourceLoaderModule.php.
Referenced by ResourceLoaderFileModule\getSkipFunction(), ResourceLoaderFileModule\readScriptFiles(), and validateScriptFile().
Definition at line 90 of file ResourceLoaderModule.php.
Referenced by getDeprecationInformation().
|
protected |
Definition at line 74 of file ResourceLoaderModule.php.
|
staticprivate |
Lazy-initialized; use self::javaScriptParser()
Definition at line 1016 of file ResourceLoaderModule.php.
Referenced by javaScriptParser().
|
protected |
Definition at line 95 of file ResourceLoaderModule.php.
Referenced by getLogger(), and setLogger().
|
protected |
Definition at line 76 of file ResourceLoaderModule.php.
|
protected |
Definition at line 70 of file ResourceLoaderModule.php.
Referenced by ResourceLoaderStartUpModule\compileUnresolvedDependencies(), ResourceLoaderStartUpModule\getConfigSettings(), getDeprecationInformation(), ResourceLoaderImageModule\getFileHashes(), ResourceLoaderImageModule\getGlobalVariants(), ResourceLoaderImageModule\getImage(), ResourceLoaderImageModule\getImages(), ResourceLoaderStartUpModule\getModuleRegistrations(), getName(), ResourceLoaderImageModule\getStyles(), ResourceLoaderWikiModule\preloadTitleInfo(), and setName().
|
protected |
Definition at line 66 of file ResourceLoaderModule.php.
Referenced by getOrigin().
|
staticprivate |
Definition at line 1017 of file ResourceLoaderModule.php.
|
protected |
Definition at line 71 of file ResourceLoaderModule.php.
Referenced by getTargets().
|
protected |
Definition at line 78 of file ResourceLoaderModule.php.
Referenced by ResourceLoaderStartUpModule\getModuleRegistrations().
const ResourceLoaderModule::LOAD_GENERAL = 'general' |
Definition at line 44 of file ResourceLoaderModule.php.
Referenced by GadgetResourceLoaderModule\getType(), getType(), ResourceLoaderWikiModule\getType(), ResourceLoaderFileModule\getType(), and GadgetsTest\provideGetType().
const ResourceLoaderModule::LOAD_STYLES = 'styles' |
Definition at line 42 of file ResourceLoaderModule.php.
Referenced by ResourceLoaderClientHtml\getData(), ResourceLoaderSiteStylesModule\getType(), ResourceLoaderUserStylesModule\getType(), GadgetResourceLoaderModule\getType(), ResourceLoaderWikiModule\getType(), ResourceLoaderImageModule\getType(), ResourceLoaderFileModule\getType(), and GadgetsTest\provideGetType().
const ResourceLoaderModule::ORIGIN_ALL = 10 |
Definition at line 60 of file ResourceLoaderModule.php.
Referenced by OutputPage\getAllowedModules().
const ResourceLoaderModule::ORIGIN_CORE_INDIVIDUAL = 2 |
Definition at line 50 of file ResourceLoaderModule.php.
Referenced by OutputPage\disallowUserJs().
const ResourceLoaderModule::ORIGIN_CORE_SITEWIDE = 1 |
Definition at line 47 of file ResourceLoaderModule.php.
const ResourceLoaderModule::ORIGIN_USER_INDIVIDUAL = 4 |
Definition at line 57 of file ResourceLoaderModule.php.
const ResourceLoaderModule::ORIGIN_USER_SITEWIDE = 3 |
Definition at line 54 of file ResourceLoaderModule.php.
Referenced by OutputPage\disallowUserJs().
const ResourceLoaderModule::TYPE_COMBINED = 'combined' |
Definition at line 38 of file ResourceLoaderModule.php.
Referenced by OutputPage\getAllowedModules(), OutputPage\getBottomScripts(), ResourceLoaderClientHtml\getHeadHtml(), and ResourceLoaderClientHtml\makeContext().
const ResourceLoaderModule::TYPE_SCRIPTS = 'scripts' |
Definition at line 36 of file ResourceLoaderModule.php.
Referenced by OutputPage\disallowUserJs(), ResourceLoaderClientHtml\getData(), ResourceLoaderClientHtml\getHeadHtml(), OutputPage\getModuleScripts(), and SpecialJavaScriptTest\plainQUnit().
const ResourceLoaderModule::TYPE_STYLES = 'styles' |
Definition at line 37 of file ResourceLoaderModule.php.
Referenced by OutputPage\buildExemptModules(), OutputPage\disallowUserJs(), ResourceLoaderClientHtml\getData(), ResourceLoaderClientHtml\getHeadHtml(), OutputPage\getModuleStyles(), ResourceLoaderClientHtml\makeLoad(), and SpecialJavaScriptTest\plainQUnit().