PureFunctions.php in X Autoload 7.5
File
tests/src/VirtualDrupal/PureFunctions.php
View source
<?php
namespace Drupal\xautoload\Tests\VirtualDrupal;
class PureFunctions {
static function moduleInvoke($module, $hook) {
$args = func_get_args();
assert($module === array_shift($args));
assert($hook === array_shift($args));
$function = $module . '_' . $hook;
if (function_exists($function)) {
return call_user_func_array($function, $args);
}
return NULL;
}
static function bootstrapHooks() {
return array(
'boot',
'exit',
'watchdog',
'language_init',
);
}
}