MediaWiki REL1_39
MediaWiki\ResourceLoader\ResourceLoader72Hack Class Reference

PHP 7.2 hack to work around the issue described at https://phabricator.wikimedia.org/T166010#5962098 Load the ResourceLoader class when MessageBlobStore is loaded. More...

Inheritance diagram for MediaWiki\ResourceLoader\ResourceLoader72Hack:
Collaboration diagram for MediaWiki\ResourceLoader\ResourceLoader72Hack:

Additional Inherited Members

- Public Member Functions inherited from MediaWiki\ResourceLoader\ResourceLoader
 __construct (Config $config, LoggerInterface $logger=null, DependencyStore $tracker=null, array $params=[])
 
 addSource ( $sources, $loadUrl=null)
 Add a foreign source of modules.
 
 createLoaderURL ( $source, Context $context, array $extraQuery=[])
 Build a load.php URL.
 
 expandUrl (string $base, string $url)
 Resolve a possibly relative URL against a base URL.
 
 getCombinedVersion (Context $context, array $moduleNames)
 Helper method to get and combine versions of multiple modules.
 
 getConfig ()
 
 getLessCompiler (array $vars=[], array $importDirs=[])
 Return a LESS compiler that is set up for use with MediaWiki.
 
 getLoadScript ( $source)
 Get the URL to the load.php endpoint for the given ResourceLoader source.
 
 getLogger ()
 
 getMessageBlobStore ()
 
 getModule ( $name)
 Get the Module object for a given module name.
 
 getModuleNames ()
 
 getModulesByMessage ( $messageKey)
 Get names of modules that use a certain message.
 
 getSources ()
 Get the list of sources.
 
 getTestSuiteModuleNames ()
 Get a list of modules with QUnit tests.
 
 isModuleRegistered ( $name)
 Check whether a ResourceLoader module is registered.
 
 loadModuleDependenciesInternal ( $moduleName, $variant)
 
 makeModuleResponse (Context $context, array $modules, array $missing=[])
 Generate code for a response.
 
 makeVersionQuery (Context $context, array $modules)
 Get the expected value of the 'version' query parameter.
 
 outputErrorAndLog (Exception $e, $msg, array $context=[])
 Add an error to the 'errors' array and log it.
 
 preloadModuleInfo (array $moduleNames, Context $context)
 Load information stored in the database and dependency tracking store about modules.
 
 register ( $name, array $info=null)
 Register a module with the ResourceLoader system.
 
 registerTestModules ()
 
 respond (Context $context)
 Output a response to a load request, including the content-type header.
 
 saveModuleDependenciesInternal ( $moduleName, $variant, $paths, $priorPaths)
 
 setDependencyStore (DependencyStore $tracker)
 
 setLogger (LoggerInterface $logger)
 
 setMessageBlobStore (MessageBlobStore $blobStore)
 
 setModuleSkinStyles (array $moduleSkinStyles)
 
- Static Public Member Functions inherited from MediaWiki\ResourceLoader\ResourceLoader
static clearCache ()
 Reset static members used for caching.
 
static encodeJsonForScript ( $data)
 Wrapper around json_encode that avoids needless escapes, and pretty-prints in debug mode.
 
static ensureNewline ( $str)
 Ensure the string is either empty or ends in a line break.
 
static expandModuleNames ( $modules)
 Expand a string of the form jquery.foo,bar|jquery.ui.baz,quux to an array of module names like ‘[ 'jquery.foo’, 'jquery.bar', 'jquery.ui.baz', 'jquery.ui.quux' ]`.
 
static filter ( $filter, $data, array $options=[])
 Run JavaScript or CSS data through a filter, caching the filtered result for future calls.
 
static formatException (Throwable $e)
 Handle exception display.
 
static getSiteConfigSettings (Context $context, Config $conf)
 Get site configuration settings to expose to JavaScript on all pages via mw.config.
 
static getUserDefaults (Context $context, HookContainer $hookContainer, UserOptionsLookup $userOptionsLookup)
 Get user default options to expose to JavaScript on all pages via mw.user.options.
 
static inDebugMode ()
 Determine whether debug mode is on.
 
static isValidModuleName ( $moduleName)
 Check a module name for validity.
 
static makeCombinedStyles (array $stylePairs)
 Combines an associative array mapping media type to CSS into a single stylesheet with "@media" blocks.
 
static makeComment ( $text)
 Generate a CSS or JS comment block.
 
static makeConfigSetScript (array $configuration)
 Return JS code which will set the MediaWiki configuration array to the given value.
 
static makeHash ( $value)
 Create a hash for module versioning purposes.
 
static makeInlineCodeWithModule ( $modules, $script)
 Wrap JavaScript code to run after a required module.
 
static makeInlineScript ( $script, $nonce=null)
 Make an HTML script that runs given JS code after startup and base modules.
 
static makeLoaderConditionalScript ( $script)
 Wrap JavaScript code to run after the startup module.
 
static makeLoaderQuery (array $modules, $lang, $skin, $user=null, $version=null, $debug=Context::DEBUG_OFF, $only=null, $printable=false, $handheld=null, array $extraQuery=[])
 Build a query array (array representation of query string) for load.php.
 
static makeLoaderRegisterScript (Context $context, array $modules)
 Format JS code which calls mw.loader.register() with the given parameters.
 
static makeLoaderSourcesScript (Context $context, array $sources)
 Format JS code which calls mw.loader.addSource() with the given parameters.
 
static makeLoaderStateScript (Context $context, array $states)
 Returns a JS call to mw.loader.state, which sets the state of modules to a given value:
 
static makeMessageSetScript ( $messages)
 Returns JS code which, when called, will register a given list of messages.
 
static makePackedModulesString (array $modules)
 Convert an array of module names to a packed query string.
 
- Public Attributes inherited from MediaWiki\ResourceLoader\ResourceLoader
const HASH_LENGTH = 5
 
- Protected Member Functions inherited from MediaWiki\ResourceLoader\ResourceLoader
 measureResponseTime ()
 Send stats about the time used to build the response.
 
 sendResponseHeaders (Context $context, $etag, $errors, array $extra=[])
 Send main response headers to the client.
 
 tryRespondFromFileCache (ResourceFileCache $fileCache, Context $context, $etag)
 Send out code for a response from file cache if possible.
 
 tryRespondNotModified (Context $context, $etag)
 Respond with HTTP 304 Not Modified if appropriate.
 
- Static Protected Member Functions inherited from MediaWiki\ResourceLoader\ResourceLoader
static createLoaderQuery (Context $context, array $extraQuery=[])
 Helper for createLoaderURL()
 
static formatExceptionNoComment (Throwable $e)
 Handle exception display.
 
- Protected Attributes inherited from MediaWiki\ResourceLoader\ResourceLoader
array $errors = []
 Errors accumulated during a respond() call.
 
string[] $extraHeaders = []
 Buffer for extra response headers during a makeModuleResponse() call.
 
- Static Protected Attributes inherited from MediaWiki\ResourceLoader\ResourceLoader
static int null $debugMode = null
 

Detailed Description

PHP 7.2 hack to work around the issue described at https://phabricator.wikimedia.org/T166010#5962098 Load the ResourceLoader class when MessageBlobStore is loaded.

phpcs:disable Generic.Files.OneObjectStructurePerFile.MultipleFound phpcs:disable MediaWiki.Files.ClassMatchesFilename.NotMatch

Definition at line 39 of file MessageBlobStore.php.


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