[ Index ] |
PHP Cross Reference of MediaWiki-1.24.0 |
[Source view] [Print] [Project Stats]
Simple script that try to find documented hook and hooks actually in the code and show what's missing. This script assumes that: - hooks names in hooks.txt are at the beginning of a line and single quoted. - hooks names in code are the first parameter of wfRunHooks.
Author: | Antoine Musso |
File Size: | 294 lines (9 kb) |
Included or required: | 0 times |
Referenced: | 0 times |
Includes or requires: | 1 file maintenance/Maintenance.php |
FindHooks:: (11 methods):
__construct()
getDbType()
execute()
getHooksFromDoc()
getHooksFromLocalDoc()
getHooksFromOnlineDoc()
getHooksFromFile()
getHooksFromPath()
getBadHooksFromFile()
getBadHooksFromPath()
printArray()
__construct() X-Ref |
No description |
getDbType() X-Ref |
No description |
execute() X-Ref |
No description |
getHooksFromDoc( $doc ) X-Ref |
Get the hook documentation, either locally or from MediaWiki.org param: string $doc return: array Array of documented hooks |
getHooksFromLocalDoc( $doc ) X-Ref |
Get hooks from a local file (for example docs/hooks.txt) param: string $doc Filename to look in return: array Array of documented hooks |
getHooksFromOnlineDoc() X-Ref |
Get hooks from www.mediawiki.org using the API return: array Array of documented hooks |
getHooksFromFile( $file ) X-Ref |
Get hooks from a PHP file param: string $file Full filename to the PHP file. return: array Array of hooks found |
getHooksFromPath( $path ) X-Ref |
Get hooks from the source code. param: string $path Directory where the include files can be found return: array Array of hooks found |
getBadHooksFromFile( $file ) X-Ref |
Get bad hooks (where the hook name could not be determined) from a PHP file param: string $file Full filename to the PHP file. return: array Array of bad wfRunHooks() lines |
getBadHooksFromPath( $path ) X-Ref |
Get bad hooks from the source code. param: string $path Directory where the include files can be found return: array Array of bad wfRunHooks() lines |
printArray( $msg, $arr, $sort = true ) X-Ref |
Nicely output the array param: string $msg A message to show before the value param: array $arr param: bool $sort Whether to sort the array (Default: true) |
Generated: Fri Nov 28 14:03:12 2014 | Cross-referenced by PHPXref 0.7.1 |