MediaWiki
1.23.2
|
Object passed around to modules which contains information about the state of a specific loader request. More...
Public Member Functions | |
__construct ( $resourceLoader, WebRequest $request) | |
getDebug () | |
getDirection () | |
getHash () | |
getLanguage () | |
getModules () | |
getOnly () | |
getRaw () | |
getRequest () | |
getResourceLoader () | |
getSkin () | |
getUser () | |
getVersion () | |
shouldIncludeMessages () | |
shouldIncludeScripts () | |
shouldIncludeStyles () | |
Static Public Member Functions | |
static | expandModuleNames ( $modules) |
Expand a string of the form jquery.foo,bar|jquery.ui.baz,quux to an array of module names like array( 'jquery.foo', 'jquery.bar', 'jquery.ui.baz', 'jquery.ui.quux' ) More... | |
static | newDummyContext () |
Return a dummy ResourceLoaderContext object suitable for passing into things that don't "really" need a context. More... | |
Protected Attributes | |
$debug | |
$direction | |
$hash | |
$language | |
$modules | |
$only | |
$raw | |
$request | |
$resourceLoader | |
$skin | |
$user | |
$version | |
Object passed around to modules which contains information about the state of a specific loader request.
Definition at line 29 of file ResourceLoaderContext.php.
ResourceLoaderContext::__construct | ( | $resourceLoader, | |
WebRequest | $request | ||
) |
$resourceLoader | ResourceLoader |
$request | WebRequest |
Definition at line 52 of file ResourceLoaderContext.php.
References $modules, $request, $resourceLoader, array(), expandModuleNames(), Skin\getSkinNames(), WebRequest\getVal(), global, only, request, skin(), user, and version.
|
static |
Expand a string of the form jquery.foo,bar|jquery.ui.baz,quux to an array of module names like array( 'jquery.foo', 'jquery.bar', 'jquery.ui.baz', 'jquery.ui.quux' )
string | $modules | Packed module name list |
Definition at line 84 of file ResourceLoaderContext.php.
References $modules, $retval, array(), and as.
Referenced by __construct(), and ResourceLoaderTest\testexpandModuleNames().
ResourceLoaderContext::getDebug | ( | ) |
Definition at line 182 of file ResourceLoaderContext.php.
References $debug.
Referenced by ResourceLoaderFileModule\getModifiedTime(), ResourceLoaderFileModule\getScriptFiles(), ResourceLoaderStartUpModule\getStartupModulesUrl(), ResourceLoader\makeModuleResponse(), ResourceLoader\sendResponseHeaders(), ResourceLoader\tryRespondFromFileCache(), and ResourceLoader\tryRespondLastModified().
ResourceLoaderContext::getDirection | ( | ) |
Definition at line 154 of file ResourceLoaderContext.php.
References $direction, Language\factory(), getLanguage(), and request.
Referenced by getHash().
ResourceLoaderContext::getHash | ( | ) |
Definition at line 231 of file ResourceLoaderContext.php.
References $hash, array(), getDirection(), getLanguage(), only, skin(), user, and version.
Referenced by ResourceLoaderUserCSSPrefsModule\getModifiedTime(), ResourceLoaderUserOptionsModule\getModifiedTime(), ResourceLoaderStartUpModule\getModifiedTime(), ResourceLoaderFileModule\getModifiedTime(), ResourceLoaderWikiModule\getTitleMtimes(), and ResourceFileCache\newFromContext().
ResourceLoaderContext::getLanguage | ( | ) |
Definition at line 143 of file ResourceLoaderContext.php.
References $language, request, and RequestContext\sanitizeLangCode().
Referenced by getDirection(), getHash(), ResourceLoaderLanguageDataModule\getModifiedHash(), ResourceLoaderWikiModule\getModifiedTime(), ResourceLoaderFileModule\getModifiedTime(), ResourceLoaderLanguageDataModule\getScript(), ResourceLoaderFileModule\getScriptFiles(), ResourceLoaderModule\getScriptURLsForDebug(), ResourceLoaderStartUpModule\getStartupModulesUrl(), ResourceLoaderModule\getStyleURLsForDebug(), ResourceLoader\makeModuleResponse(), and ResourceLoader\preloadModuleInfo().
ResourceLoaderContext::getModules | ( | ) |
Definition at line 136 of file ResourceLoaderContext.php.
References $modules.
Referenced by ResourceFileCache\newFromContext().
ResourceLoaderContext::getOnly | ( | ) |
Definition at line 189 of file ResourceLoaderContext.php.
References $only.
Referenced by ResourceLoaderStartUpModule\getScript(), ResourceLoader\makeModuleResponse(), ResourceFileCache\newFromContext(), and ResourceLoader\sendResponseHeaders().
ResourceLoaderContext::getRaw | ( | ) |
Definition at line 203 of file ResourceLoaderContext.php.
References $raw.
Referenced by ResourceLoader\makeModuleResponse().
ResourceLoaderContext::getRequest | ( | ) |
Definition at line 129 of file ResourceLoaderContext.php.
References $request.
Referenced by ResourceLoaderStartUpModule\getModuleRegistrations(), ResourceLoaderUserModule\getPages(), ResourceLoaderModule\getScriptURLsForDebug(), ResourceLoaderModule\getStyleURLsForDebug(), ResourceLoader\tryRespondLastModified(), and ResourceFileCache\useFileCache().
ResourceLoaderContext::getResourceLoader | ( | ) |
Definition at line 122 of file ResourceLoaderContext.php.
References $resourceLoader.
Referenced by ResourceLoaderStartUpModule\getModifiedTime(), ResourceLoaderStartUpModule\getModuleRegistrations(), and ResourceLoaderStartUpModule\getStartupModulesUrl().
ResourceLoaderContext::getSkin | ( | ) |
Definition at line 168 of file ResourceLoaderContext.php.
References $skin.
Referenced by ResourceLoaderFileModule\getModifiedTime(), ResourceLoaderSiteModule\getPages(), ResourceLoaderUserModule\getPages(), ResourceLoaderFileModule\getScriptFiles(), ResourceLoaderModule\getScriptURLsForDebug(), ResourceLoaderStartUpModule\getStartupModulesUrl(), ResourceLoaderFileModule\getStyleFiles(), ResourceLoaderFileModule\getStyles(), ResourceLoaderModule\getStyleURLsForDebug(), and ResourceLoader\preloadModuleInfo().
ResourceLoaderContext::getUser | ( | ) |
Definition at line 175 of file ResourceLoaderContext.php.
References $user.
Referenced by ResourceLoaderUserGroupsModule\getPages(), ResourceLoaderUserModule\getPages(), ResourceLoaderModule\getScriptURLsForDebug(), and ResourceLoaderModule\getStyleURLsForDebug().
ResourceLoaderContext::getVersion | ( | ) |
Definition at line 196 of file ResourceLoaderContext.php.
References $version.
Referenced by ResourceLoaderModule\getScriptURLsForDebug(), ResourceLoaderModule\getStyleURLsForDebug(), ResourceLoader\sendResponseHeaders(), and ResourceLoader\tryRespondFromFileCache().
|
static |
Return a dummy ResourceLoaderContext object suitable for passing into things that don't "really" need a context.
Definition at line 115 of file ResourceLoaderContext.php.
References array().
ResourceLoaderContext::shouldIncludeMessages | ( | ) |
Definition at line 224 of file ResourceLoaderContext.php.
References only.
Referenced by ResourceLoader\makeModuleResponse().
ResourceLoaderContext::shouldIncludeScripts | ( | ) |
Definition at line 210 of file ResourceLoaderContext.php.
References only.
Referenced by ResourceLoader\makeModuleResponse().
ResourceLoaderContext::shouldIncludeStyles | ( | ) |
Definition at line 217 of file ResourceLoaderContext.php.
References only.
Referenced by ResourceLoader\makeModuleResponse().
|
protected |
Definition at line 40 of file ResourceLoaderContext.php.
Referenced by getDebug().
|
protected |
Definition at line 37 of file ResourceLoaderContext.php.
Referenced by getDirection().
|
protected |
Definition at line 43 of file ResourceLoaderContext.php.
Referenced by getHash().
|
protected |
Definition at line 36 of file ResourceLoaderContext.php.
Referenced by getLanguage().
|
protected |
Definition at line 35 of file ResourceLoaderContext.php.
Referenced by __construct(), expandModuleNames(), and getModules().
|
protected |
Definition at line 41 of file ResourceLoaderContext.php.
Referenced by getOnly().
|
protected |
Definition at line 44 of file ResourceLoaderContext.php.
Referenced by getRaw().
|
protected |
Definition at line 34 of file ResourceLoaderContext.php.
Referenced by __construct(), and getRequest().
|
protected |
Definition at line 33 of file ResourceLoaderContext.php.
Referenced by __construct(), and getResourceLoader().
|
protected |
Definition at line 38 of file ResourceLoaderContext.php.
Referenced by getSkin().
|
protected |
Definition at line 39 of file ResourceLoaderContext.php.
Referenced by getUser().
|
protected |
Definition at line 42 of file ResourceLoaderContext.php.
Referenced by getVersion().