public static function Check::classExists in Hook Update Deploy Tools 7
Same name and namespace in other branches
- 8 src/Check.php \HookUpdateDeployTools\Check::classExists()
Evaluates if a class exists.
Parameters
string $class: The full namespaced name of a class.
Return value
bool TRUE if the class exists.
Throws
HudtException non-logging if the class does not exist.
2 calls to Check::classExists()
- drush_hook_update_deploy_tools_site_deploy_export in ./
hook_update_deploy_tools.drush.inc - Drush command to export anything that implements the ExportInterface.
- drush_hook_update_deploy_tools_site_deploy_import in ./
hook_update_deploy_tools.drush.inc - Drush command to import anything that implements the ImportInterface.
File
- src/
Check.php, line 74 - File for methods related to strictly checking things.
Class
- Check
- Public methods for dealing with Checking things.
Namespace
HookUpdateDeployToolsCode
public static function classExists($class) {
if (!empty($class) && class_exists($class)) {
return TRUE;
}
else {
$message = "The class @class does not exist and can not be used.";
$vars = array(
'@class' => $class,
);
throw new HudtException($message, $vars, WATCHDOG_ERROR, FALSE);
}
}