From: hickert Date: Wed, 23 Jan 2008 10:12:27 +0000 (+0000) Subject: Added function to check the availability of a class. X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=c3cb681d40cb699163393527e2ea52368a5aec3e;p=gosa.git Added function to check the availability of a class. git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@8558 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-core/include/functions.inc b/gosa-core/include/functions.inc index b043a06f9..76702935f 100644 --- a/gosa-core/include/functions.inc +++ b/gosa-core/include/functions.inc @@ -109,6 +109,17 @@ function __autoload($class_name) { } +/*! \brief Checks if a class is available. + * @param name String The class name. + * @return boolean True if class is available, else false. + */ +function class_available($name) +{ + global $class_mapping; + return(isset($class_mapping[$name])); +} + + /* Check if plugin is avaliable */ function plugin_available($plugin) {