Extension:Translate/Hooks/TranslatePostInitGroups

From mediawiki.org
TranslatePostInitGroups
Available from version ???
Hook to register new message groups to Translate. Manual cache clear may be needed to have this hook executed.
Define function:
public static function onTranslatePostInitGroups( &$groups, &$deps, &$autoload ) { ... }
Attach hook:
$wgHooks['TranslatePostInitGroups'][] = 'MyExtensionHooks::onTranslatePostInitGroups';
Called from:File(s): Translate / MessageGroups.php
Function(s): getCachedGroupDefinitions

For more information about attaching hooks, see Manual:Hooks .
For examples of other extensions using this hook, see Category:TranslatePostInitGroups extensions.

Details[edit]

  • array &$groups: Map of message group id to message group instance
  • array &$deps: List of dependencies as supported by DependecyWrapper class from MediaWiki
  • array &$autoload: List of autoloaded classes. Key is the name of the class and value is filename.