diff --git a/gosa-core/include/class_configRegistry.inc b/gosa-core/include/class_configRegistry.inc
index 47355e5747c17b980a253698bb6a1e878732ccae..ee68d2ed46836ec343471604dde32eb23770a94c 100644 (file)
$this->reload();
}
$this->reload();
}
+
+ /*! \brief Returns a list of plugins used by GOsa.
+ @return Array An array containing all plugins with theis plInfo data.
+ */
+ function getListOfPlugins()
+ {
+ return($this->classesWithInfo);
+ }
+
/*! \brief Checks whether the schema check was called in the current session or not.
* @return Boolean True if check was already called
/*! \brief Checks whether the schema check was called in the current session or not.
* @return Boolean True if check was already called
foreach($this->classesWithInfo as $cname => $defs){
if(isset($defs['plRequirements'])){
foreach($this->classesWithInfo as $cname => $defs){
if(isset($defs['plRequirements'])){
+ // Check only if required plugin is enabled in gosa.conf
+ // Normally this is the class name itself, but may be overridden
+ // in plInfo using the plRequirements::activePlugin statement.
+ $requiresActivePlugin = $cname;
+ if(isset($defs['plRequirements']['activePlugin'])){
+ $requiresActivePlugin = $defs['plRequirements']['activePlugin'];
+ }
+
// Only queue checks for active plugins.
// Only queue checks for active plugins.
- if(isset($this->activePlugins[strtolower($cname)])){
+ if(isset($this->activePlugins[strtolower($requiresActivePlugin)])){
$this->pluginRequirements[$cname] = $defs['plRequirements'];
}else{
$this->pluginRequirements[$cname] = $defs['plRequirements'];
}else{
- new log("debug","schemaValidation","Skipped schema check for '{$cname}' plugin is inactive!",
- array(),'');
+ if($cname == $requiresActivePlugin){
+ new log("debug","","Skipped schema check for '{$cname}' plugin is inactive!",
+ array(),'');
+ }else{
+ new log("debug","","Skipped schema check for class '{$cname}' skipped,".
+ " required plugin '{$requiresActivePlugin}' is inactive!",
+ array(),'');
+ }
}
}
}
}
}
}
$this->schemaCheckFailed = TRUE;
$failure = TRUE;
$this->schemaCheckFailed = TRUE;
$failure = TRUE;
- new log("debug","schemaValidation","LDAP objectClass missing '{$oc}'!",
+ new log("debug","","LDAP objectClass missing '{$oc}'!",
array(),'');
}elseif(!empty($version)){
array(),'');
}elseif(!empty($version)){
$this->schemaCheckFailed = TRUE;
$failure = TRUE;
$this->schemaCheckFailed = TRUE;
$failure = TRUE;
- new log("debug","schemaValidation","LDAP objectClass version mismatch '{$oc}' ".
+ new log("debug","","LDAP objectClass version mismatch '{$oc}' ".
"has '{$currentVersion}' but {$version} required!",
array(),'');
}
"has '{$currentVersion}' but {$version} required!",
array(),'');
}
$this->ldapStoredProperties[$class][$name] = $value;
}
}
$this->ldapStoredProperties[$class][$name] = $value;
}
}
- $this->status = 'finished';
}
// Register plugin properties.
}
// Register plugin properties.
$this->register($cname, $data);
$data = array('name' => 'postmodify','type' => 'command');
$this->register($cname, $data);
$this->register($cname, $data);
$data = array('name' => 'postmodify','type' => 'command');
$this->register($cname, $data);
+ $data = array('name' => 'precreate','type' => 'command');
+ $this->register($cname, $data);
+ $data = array('name' => 'preremove','type' => 'command');
+ $this->register($cname, $data);
+ $data = array('name' => 'premodify','type' => 'command');
+ $this->register($cname, $data);
$data = array('name' => 'check', 'type' => 'command');
$this->register($cname, $data);
$data = array('name' => 'check', 'type' => 'command');
$this->register($cname, $data);
}
}
}
}
}
}
+
+ // We are only finsihed once we are logged in.
+ if(!empty($this->config->current['CONFIG'])){
+ $this->status = 'finished';
+ }
+ }
+
+
+ /*! \brief Returns TRUE if the property registration has finished without any error.
+ */
+ function propertyInitializationComplete()
+ {
+ return($this->status == 'finished');
}
}