for more flexibility with different LDAP tree structures.
protected $searches;
/**
+ * The structure handler for this server.
+ *
+ * @var Horde_Kolab_Server_Structure
+ */
+ public $structure;
+
+ /**
* Construct a new Horde_Kolab_Server object.
*
* @param array $params Parameter array.
$this->uid = $params['uid'];
}
+ $structure = isset($params['structure']['driver'])
+ ? $params['structure']['driver'] : 'kolab';
+ $structure_params = isset($params['structure']['params'])
+ ? $params['structure']['params'] : array();
+
+ $this->structure = &Horde_Kolab_Server_Structure::factory($structure,
+ $this,
+ $structure_params);
+
// Initialize the search operations supported by this server.
$this->searches = $this->getSearchOperations();
}
}
/**
- * Returns the set of objects supported by this server type.
+ * Returns the set of objects supported by this server.
*
- * @return array An array of supported search operations.
+ * @return array An array of supported objects.
+ */
+ public function getSupportedObjects()
+ {
+ return $this->structure->getSupportedObjects();
+ }
+
+ /**
+ * Determine the type of an object by its tree position and other
+ * parameters.
+ *
+ * @param string $uid The UID of the object to examine.
+ *
+ * @return string The class name of the corresponding object type.
+ *
+ * @throws Horde_Kolab_Server_Exception If the object type is unknown.
+ */
+ public function determineType($uid)
+ {
+ return $this->structure->determineType($uid);
+ }
+
+ /**
+ * Generates a UID for the given information.
+ *
+ * @param string $type The class name of the object to create.
+ * @param string $id The id of the object.
+ * @param array $info Any additional information about the object to create.
+ *
+ * @return string The UID.
+ *
+ * @throws Horde_Kolab_Server_Exception
*/
- static public function getSupportedObjects()
+ protected function generateServerUid($type, $id, $info)
{
- $objects = array(
- 'Horde_Kolab_Server_Object',
- );
- return $objects;
+ return $this->structure->generateServerUid($type, $id, $info);
}
/**
{
$server_searches = array();
foreach ($this->getSupportedObjects() as $sobj) {
- $searches = call_user_func(array($sobj, 'getSearchOperations'));
- foreach ($searches as $search) {
- $server_searches[$search] = array('class' => $sobj);
+ if (in_array('getSearchOperations', get_class_methods($sobj))) {
+ $searches = call_user_func(array($sobj, 'getSearchOperations'));
+ foreach ($searches as $search) {
+ $server_searches[$search] = array('class' => $sobj);
+ }
}
}
return $server_searches;
abstract public function save($uid, $data, $exists = false);
/**
- * Determine the type of a Kolab object.
- *
- * @param string $uid The UID of the object to examine.
- *
- * @return string The corresponding Kolab object type.
- *
- * @throws Horde_Kolab_Server_Exception
- */
- abstract protected function determineType($uid);
-
- /**
* List all objects of a specific type
*
* @param string $type The type of the objects to be listed
abstract public function listObjects($type, $params = null);
/**
- * Generates a UID for the given information.
- *
- * @param string $type The type of the object to create.
- * @param string $id The id of the object.
- * @param array $info Any additional information about the object to create.
- *
- * @return string The UID.
- *
- * @throws Horde_Kolab_Server_Exception
- */
- abstract protected function generateServerUid($type, $id, $info);
-
- /**
* Return the root of the UID values on this server.
*
* @return string The base UID on this server (base DN on ldap).
+++ /dev/null
-<?php
-/**
- * The driver for accessing the Kolab user database stored in LDAP.
- *
- * PHP version 5
- *
- * @category Kolab
- * @package Kolab_Server
- * @author Gunnar Wrobel <wrobel@pardus.de>
- * @license http://www.fsf.org/copyleft/lgpl.html LGPL
- * @link http://pear.horde.org/index.php?package=Kolab_Server
- */
-
-/**
- * This class provides methods to deal with Kolab objects stored in
- * the standard Kolab LDAP db.
- *
- * Copyright 2008-2009 The Horde Project (http://www.horde.org/)
- *
- * See the enclosed file COPYING for license information (LGPL). If you
- * did not receive this file, see http://www.fsf.org/copyleft/lgpl.html.
- *
- * @category Kolab
- * @package Kolab_Server
- * @author Gunnar Wrobel <wrobel@pardus.de>
- * @license http://www.fsf.org/copyleft/lgpl.html LGPL
- * @link http://pear.horde.org/index.php?package=Kolab_Server
- */
-class Horde_Kolab_Server_Kolab extends Horde_Kolab_Server_Ldap
-{
- /**
- * Returns the set of objects supported by this server type.
- *
- * @return array An array of supported search operations.
- */
- static public function getSupportedObjects()
- {
- $objects = array(
- 'Horde_Kolab_Server_Object',
- 'Horde_Kolab_Server_Object_Groupofnames',
- 'Horde_Kolab_Server_Object_Kolabinetorgperson',
- 'Horde_Kolab_Server_Object_Kolabgroupofnames',
- );
- return $objects;
- }
-
- /**
- * Determine the type of a Kolab object.
- *
- * @param string $dn The DN of the object to examine.
- *
- * @return int The corresponding Kolab object type.
- *
- * @throws Horde_Kolab_Server_Exception If the object type is unknown.
- */
- public function determineType($dn)
- {
- $oc = $this->getObjectClasses($dn);
- // Not a user type?
- if (!in_array('kolabinetorgperson', $oc)) {
- // Is it a group?
- if (in_array('kolabgroupofnames', $oc)) {
- return 'Horde_Kolab_Server_Object_Kolabgroupofnames';
- }
- // Is it a shared Folder?
- if (in_array('kolabsharedfolder', $oc)) {
- return 'Horde_Kolab_Server_Object_Kolabsharedfolder';
- }
- return parent::determineType($dn);
- }
-
- $groups = $this->getGroups($dn);
- if (!empty($groups)) {
- if (in_array('cn=admin,cn=internal,' . $this->getBaseUid(), $groups)) {
- return 'Horde_Kolab_Server_Object_Kolab_Administrator';
- }
- if (in_array('cn=maintainer,cn=internal,' . $this->getBaseUid(),
- $groups)) {
- return 'Horde_Kolab_Server_Object_Kolab_Maintainer';
- }
- if (in_array('cn=domain-maintainer,cn=internal,' . $this->getBaseUid(),
- $groups)) {
- return 'Horde_Kolab_Server_Object_Kolab_Domainmaintainer';
- }
- }
-
- if (strpos($dn, 'cn=external') !== false) {
- return 'Horde_Kolab_Server_Object_Kolab_Address';
- }
-
- return 'Horde_Kolab_Server_Object_Kolab_User';
- }
-
- /**
- * Generates a UID for the given information.
- *
- * @param string $type The type of the object to create.
- * @param string $id The id of the object.
- * @param array $info Any additional information about the object to create.
- *
- * @return string The DN.
- *
- * @throws Horde_Kolab_Server_Exception If the given type is unknown.
- */
- public function generateServerUid($type, $id, $info)
- {
- switch ($type) {
- case 'Horde_Kolab_Server_Object_Kolab_User':
- if (empty($info['user_type'])) {
- return parent::generateServerUid($type, $id, $info);
- } else if ($info['user_type'] == Horde_Kolab_Server_Object_Kolab_User::USERTYPE_INTERNAL) {
- return sprintf('%s,cn=internal,%s', $id, $this->getBaseUid());
- } else if ($info['user_type'] == Horde_Kolab_Server_Object_Kolab_User::USERTYPE_GROUP) {
- return sprintf('%s,cn=groups,%s', $id, $this->getBaseUid());
- } else if ($info['user_type'] == Horde_Kolab_Server_Object_Kolab_User::USERTYPE_RESOURCE) {
- return sprintf('%s,cn=resources,%s', $id, $this->getBaseUid());
- } else {
- return parent::generateServerUid($type, $id, $info);
- }
- case 'Horde_Kolab_Server_Object_Kolab_Address':
- return sprintf('%s,cn=external,%s', $id, $this->getBaseUid());
- case 'Horde_Kolab_Server_Object_Kolabgroupofnames':
- case 'Horde_Kolab_Server_Object_Kolab_Distlist':
- if (!isset($info['visible']) || !empty($info['visible'])) {
- return parent::generateServerUid($type, $id, $info);
- } else {
- return sprintf('%s,cn=internal,%s', $id, $this->getBaseUid());
- }
- case 'Horde_Kolab_Server_Object_Kolabsharedfolder':
- case 'Horde_Kolab_Server_Object_Kolab_Administrator':
- case 'Horde_Kolab_Server_Object_Kolab_Maintainer':
- case 'Horde_Kolab_Server_Object_Kolab_Domainmaintainer':
- default:
- return parent::generateServerUid($type, $id, $info);
- }
- }
-}
return $clause;
}
-
- /**
- * Determine the type of a Kolab object.
- *
- * @param string $uid The UID of the object to examine.
- *
- * @return int The corresponding Kolab object type.
- *
- * @throws Horde_Kolab_Server_Exception If the object type is unknown.
- */
- public function determineType($uid)
- {
- $ocs = $this->getObjectClasses($uid);
- $ocs = array_reverse($ocs);
- foreach ($ocs as $oc) {
- try {
- $class_name = 'Horde_Kolab_Server_Object_' . ucfirst(strtolower($oc));
- Horde_Kolab_Server_Object::loadClass($class_name);
- return $class_name;
- } catch (Horde_Kolab_Server_Exception $e) {
- }
- }
- if ($oc == 'top') {
- return 'Horde_Kolab_Server_Object';
- }
- throw new Horde_Kolab_Server_Exception(sprintf(_("Unkown object type for UID %s."),
- $uid));
- }
-
- /**
- * Generates a UID for the given information.
- *
- * @param string $type The type of the object to create.
- * @param string $id The id of the object.
- * @param array $info Any additional information about the object to create.
- *
- * @return string The DN.
- *
- * @throws Horde_Kolab_Server_Exception If the given type is unknown.
- */
- public function generateServerUid($type, $id, $info)
- {
- switch ($type) {
- default:
- return sprintf('%s,%s', $id, $this->getBaseUid());
- }
- }
}
--- /dev/null
+<?php
+/**
+ * A simple structural handler for a tree of objects.
+ *
+ * PHP version 5
+ *
+ * @category Kolab
+ * @package Kolab_Server
+ * @author Gunnar Wrobel <wrobel@pardus.de>
+ * @license http://www.fsf.org/copyleft/lgpl.html LGPL
+ * @link http://pear.horde.org/index.php?package=Kolab_Server
+ */
+
+/**
+ * An abstract class definiing methods to deal with an object tree structure.
+ *
+ * Copyright 2009 The Horde Project (http://www.horde.org/)
+ *
+ * See the enclosed file COPYING for license information (LGPL). If you
+ * did not receive this file, see http://www.fsf.org/copyleft/lgpl.html.
+ *
+ * @category Kolab
+ * @package Kolab_Server
+ * @author Gunnar Wrobel <wrobel@pardus.de>
+ * @license http://www.fsf.org/copyleft/lgpl.html LGPL
+ * @link http://pear.horde.org/index.php?package=Kolab_Server
+ */
+abstract class Horde_Kolab_Server_Structure
+{
+ /**
+ * A link to the server handler.
+ *
+ * @var Horde_Kolab_Server
+ */
+ protected $server;
+
+ /**
+ * Structure parameters.
+ *
+ * @var array
+ */
+ protected $params = array();
+
+ /**
+ * Construct a new Horde_Kolab_Server_Structure object.
+ *
+ * @param Horde_Kolab_Server &$server A link to the server handler.
+ * @param array $params Parameter array.
+ */
+ public function __construct(&$server, $params = array())
+ {
+ $this->server = &$server;
+ $this->params = $params;
+ }
+
+ /**
+ * Attempts to return a concrete Horde_Kolab_Server_Structure instance based
+ * on $driver.
+ *
+ * @param mixed $driver The type of concrete Horde_Kolab_Server
+ * subclass to return.
+ * @param Horde_Kolab_Server &$server A link to the server handler .
+ * @param array $params A hash containing any additional
+ * configuration or connection
+ * parameters a subclass might need.
+ *
+ * @return Horde_Kolab_Server_Structure The newly created concrete
+ * Horde_Kolab_Server_Structure instance.
+ *
+ * @throws Horde_Kolab_Server_Exception If the requested Horde_Kolab_Server_Structure
+ * subclass could not be found.
+ */
+ static public function &factory($driver, &$server, $params = array())
+ {
+ if (class_exists($driver)) {
+ $class = $driver;
+ } else {
+ $class = 'Horde_Kolab_Server_Structure_' . ucfirst(basename($driver));
+ if (!class_exists($class)) {
+ throw new Horde_Kolab_Server_Exception(
+ 'Structure type definition "' . $class . '" missing.');
+ }
+ }
+ $structure = new $class($server, $params);
+ return $structure;
+ }
+
+ /**
+ * Returns the set of objects supported by this structure.
+ *
+ * @return array An array of supported objects.
+ */
+ abstract public function getSupportedObjects();
+
+ /**
+ * Determine the type of an object by its tree position and other
+ * parameters.
+ *
+ * @param string $uid The UID of the object to examine.
+ *
+ * @return string The class name of the corresponding object type.
+ *
+ * @throws Horde_Kolab_Server_Exception If the object type is unknown.
+ */
+ abstract public function determineType($uid);
+
+ /**
+ * Generates a UID for the given information.
+ *
+ * @param string $type The class name of the object to create.
+ * @param string $id The id of the object.
+ * @param array $info Any additional information about the object to create.
+ *
+ * @return string The UID.
+ *
+ * @throws Horde_Kolab_Server_Exception If the given type is unknown.
+ */
+ abstract public function generateServerUid($type, $id, $info);
+}
--- /dev/null
+<?php
+/**
+ * The driver for handling the Kolab user database structure.
+ *
+ * PHP version 5
+ *
+ * @category Kolab
+ * @package Kolab_Server
+ * @author Gunnar Wrobel <wrobel@pardus.de>
+ * @license http://www.fsf.org/copyleft/lgpl.html LGPL
+ * @link http://pear.horde.org/index.php?package=Kolab_Server
+ */
+
+/**
+ * This class provides methods to deal with Kolab objects stored in
+ * the standard Kolab LDAP db.
+ *
+ * Copyright 2008-2009 The Horde Project (http://www.horde.org/)
+ *
+ * See the enclosed file COPYING for license information (LGPL). If you
+ * did not receive this file, see http://www.fsf.org/copyleft/lgpl.html.
+ *
+ * @category Kolab
+ * @package Kolab_Server
+ * @author Gunnar Wrobel <wrobel@pardus.de>
+ * @license http://www.fsf.org/copyleft/lgpl.html LGPL
+ * @link http://pear.horde.org/index.php?package=Kolab_Server
+ */
+class Horde_Kolab_Server_Structure_Kolab extends Horde_Kolab_Server_Structure_Ldap
+{
+ /**
+ * Returns the set of objects supported by this structure.
+ *
+ * @return array An array of supported objects.
+ */
+ public function getSupportedObjects()
+ {
+ return array(
+ 'Horde_Kolab_Server_Object',
+ 'Horde_Kolab_Server_Object_Groupofnames',
+ 'Horde_Kolab_Server_Object_Kolabinetorgperson',
+ 'Horde_Kolab_Server_Object_Kolabgroupofnames',
+ 'Horde_Kolab_Server_Object_Kolabsharedfolder',
+ 'Horde_Kolab_Server_Object_Kolab_Address',
+ 'Horde_Kolab_Server_Object_Kolab_Administrator',
+ 'Horde_Kolab_Server_Object_Kolab_Distlist',
+ 'Horde_Kolab_Server_Object_Kolab_Domainmaintainer',
+ 'Horde_Kolab_Server_Object_Kolab_Maintainer',
+ 'Horde_Kolab_Server_Object_Kolab_Server',
+ 'Horde_Kolab_Server_Object_Kolab_User',
+ );
+ }
+
+ /**
+ * Determine the type of an object by its tree position and other
+ * parameters.
+ *
+ * @param string $uid The UID of the object to examine.
+ *
+ * @return string The class name of the corresponding object type.
+ *
+ * @throws Horde_Kolab_Server_Exception If the object type is unknown.
+ */
+ public function determineType($uid)
+ {
+ $oc = $this->server->getObjectClasses($uid);
+ // Not a user type?
+ if (!in_array('kolabinetorgperson', $oc)) {
+ // Is it a group?
+ if (in_array('kolabgroupofnames', $oc)) {
+ return 'Horde_Kolab_Server_Object_Kolabgroupofnames';
+ }
+ // Is it a shared Folder?
+ if (in_array('kolabsharedfolder', $oc)) {
+ return 'Horde_Kolab_Server_Object_Kolabsharedfolder';
+ }
+ return parent::determineType($uid);
+ }
+
+ $groups = $this->server->getGroups($uid);
+ if (!empty($groups)) {
+ if (in_array('cn=admin,cn=internal,' . $this->server->getBaseUid(), $groups)) {
+ return 'Horde_Kolab_Server_Object_Kolab_Administrator';
+ }
+ if (in_array('cn=maintainer,cn=internal,' . $this->server->getBaseUid(),
+ $groups)) {
+ return 'Horde_Kolab_Server_Object_Kolab_Maintainer';
+ }
+ if (in_array('cn=domain-maintainer,cn=internal,' . $this->server->getBaseUid(),
+ $groups)) {
+ return 'Horde_Kolab_Server_Object_Kolab_Domainmaintainer';
+ }
+ }
+
+ if (strpos($uid, 'cn=external') !== false) {
+ return 'Horde_Kolab_Server_Object_Kolab_Address';
+ }
+
+ return 'Horde_Kolab_Server_Object_Kolab_User';
+ }
+
+ /**
+ * Generates a UID for the given information.
+ *
+ * @param string $type The class name of the object to create.
+ * @param string $id The id of the object.
+ * @param array $info Any additional information about the object to create.
+ *
+ * @return string The UID.
+ *
+ * @throws Horde_Kolab_Server_Exception If the given type is unknown.
+ */
+ public function generateServerUid($type, $id, $info)
+ {
+ switch ($type) {
+ case 'Horde_Kolab_Server_Object_Kolab_User':
+ if (empty($info['user_type'])) {
+ return parent::generateServerUid($type, $id, $info);
+ } else if ($info['user_type'] == Horde_Kolab_Server_Object_Kolab_User::USERTYPE_INTERNAL) {
+ return sprintf('%s,cn=internal,%s', $id, $this->server->getBaseUid());
+ } else if ($info['user_type'] == Horde_Kolab_Server_Object_Kolab_User::USERTYPE_GROUP) {
+ return sprintf('%s,cn=groups,%s', $id, $this->server->getBaseUid());
+ } else if ($info['user_type'] == Horde_Kolab_Server_Object_Kolab_User::USERTYPE_RESOURCE) {
+ return sprintf('%s,cn=resources,%s', $id, $this->server->getBaseUid());
+ } else {
+ return parent::generateServerUid($type, $id, $info);
+ }
+ case 'Horde_Kolab_Server_Object_Kolab_Address':
+ return sprintf('%s,cn=external,%s', $id, $this->server->getBaseUid());
+ case 'Horde_Kolab_Server_Object_Kolabgroupofnames':
+ case 'Horde_Kolab_Server_Object_Kolab_Distlist':
+ if (!isset($info['visible']) || !empty($info['visible'])) {
+ return parent::generateServerUid($type, $id, $info);
+ } else {
+ return sprintf('%s,cn=internal,%s', $id, $this->server->getBaseUid());
+ }
+ case 'Horde_Kolab_Server_Object_Kolabsharedfolder':
+ case 'Horde_Kolab_Server_Object_Kolab_Administrator':
+ case 'Horde_Kolab_Server_Object_Kolab_Maintainer':
+ case 'Horde_Kolab_Server_Object_Kolab_Domainmaintainer':
+ default:
+ return parent::generateServerUid($type, $id, $info);
+ }
+ }
+}
--- /dev/null
+<?php
+/**
+ * A structural handler for the tree of objects stored in LDAP.
+ *
+ * PHP version 5
+ *
+ * @category Kolab
+ * @package Kolab_Server
+ * @author Gunnar Wrobel <wrobel@pardus.de>
+ * @license http://www.fsf.org/copyleft/lgpl.html LGPL
+ * @link http://pear.horde.org/index.php?package=Kolab_Server
+ */
+
+/**
+ * This class provides methods to deal with the LDAP tree structure.
+ *
+ * Copyright 2008-2009 The Horde Project (http://www.horde.org/)
+ *
+ * See the enclosed file COPYING for license information (LGPL). If you
+ * did not receive this file, see http://www.fsf.org/copyleft/lgpl.html.
+ *
+ * @category Kolab
+ * @package Kolab_Server
+ * @author Gunnar Wrobel <wrobel@pardus.de>
+ * @license http://www.fsf.org/copyleft/lgpl.html LGPL
+ * @link http://pear.horde.org/index.php?package=Kolab_Server
+ */
+class Horde_Kolab_Server_Structure_Ldap extends Horde_Kolab_Server_Structure
+{
+ /**
+ * Returns the set of objects supported by this structure.
+ *
+ * @return array An array of supported objects.
+ */
+ public function getSupportedObjects()
+ {
+ return array(
+ 'Horde_Kolab_Server_Object',
+ );
+ }
+
+ /**
+ * Determine the type of an object by its tree position and other
+ * parameters.
+ *
+ * @param string $uid The UID of the object to examine.
+ *
+ * @return string The class name of the corresponding object type.
+ *
+ * @throws Horde_Kolab_Server_Exception If the object type is unknown.
+ */
+ public function determineType($uid)
+ {
+ $ocs = $this->server->getObjectClasses($uid);
+ $ocs = array_reverse($ocs);
+ foreach ($ocs as $oc) {
+ try {
+ $class_name = 'Horde_Kolab_Server_Object_' . ucfirst(strtolower($oc));
+ Horde_Kolab_Server_Object::loadClass($class_name);
+ return $class_name;
+ } catch (Horde_Kolab_Server_Exception $e) {
+ }
+ }
+ if ($oc == 'top') {
+ return 'Horde_Kolab_Server_Object';
+ }
+ throw new Horde_Kolab_Server_Exception(sprintf(_("Unkown object type for UID %s."),
+ $uid));
+ }
+
+ /**
+ * Generates a UID for the given information.
+ *
+ * @param string $type The class name of the object to create.
+ * @param string $id The id of the object.
+ * @param array $info Any additional information about the object to create.
+ *
+ * @return string The UID.
+ *
+ * @throws Horde_Kolab_Server_Exception If the given type is unknown.
+ */
+ public function generateServerUid($type, $id, $info)
+ {
+ return sprintf('%s,%s', $id, $this->server->getBaseUid());
+ }
+}
* @license http://www.fsf.org/copyleft/lgpl.html LGPL
* @link http://pear.horde.org/index.php?package=Kolab_Server
*/
-class Horde_Kolab_Server_Test extends Horde_Kolab_Server_Kolab
+class Horde_Kolab_Server_Test extends Horde_Kolab_Server_Ldap
{
/**
<dir name="Server">
<file name="Exception.php" role="php" />
<file name="File.php" role="php" />
- <file name="Kolab.php" role="php" />
<file name="Ldap.php" role="php" />
<file name="MissingObjectException.php" role="php" />
<file name="Object.php" role="php" />
<file name="User.php" role="php" />
</dir> <!-- /lib/Horde/Kolab/Server/Object/Kolab -->
</dir> <!-- /lib/Horde/Kolab/Server/Object -->
+ <file name="Structure.php" role="php" />
+ <dir name="Structure">
+ <file name="Kolab.php" role="php" />
+ <file name="Ldap.php" role="php" />
+ </dir> <!-- /lib/Horde/Kolab/Server/Structure -->
<file name="Test.php" role="php" />
<dir name="Test">
<file name="Search.php" role="php" />
<install name="lib/Horde/Kolab/Test/Server.php" as="Horde/Kolab/Test/Server.php" />
<install name="lib/Horde/Kolab/Server/Exception.php" as="Horde/Kolab/Server/Exception.php" />
<install name="lib/Horde/Kolab/Server/File.php" as="Horde/Kolab/Server/File.php" />
- <install name="lib/Horde/Kolab/Server/Kolab.php" as="Horde/Kolab/Server/Kolab.php" />
<install name="lib/Horde/Kolab/Server/Ldap.php" as="Horde/Kolab/Server/Ldap.php" />
<install name="lib/Horde/Kolab/Server/MissingObjectException.php" as="Horde/Kolab/Server/MissingObjectException.php" />
<install name="lib/Horde/Kolab/Server/Object.php" as="Horde/Kolab/Server/Object.php" />
<install name="lib/Horde/Kolab/Server/Object/Kolab/User.php" as="Horde/Kolab/Server/Object/Kolab/User.php" />
<install name="lib/Horde/Kolab/Server/Object/Organizationalperson.php" as="Horde/Kolab/Server/Object/Organizationalperson.php" />
<install name="lib/Horde/Kolab/Server/Object/Person.php" as="Horde/Kolab/Server/Object/Person.php" />
+ <install name="lib/Horde/Kolab/Server/Structure.php" as="Horde/Kolab/Server/Structure.php" />
+ <install name="lib/Horde/Kolab/Server/Structure/Kolab.php" as="Horde/Kolab/Server/Structure/Kolab.php" />
+ <install name="lib/Horde/Kolab/Server/Structure/Ldap.php" as="Horde/Kolab/Server/Structure/Ldap.php" />
<install name="lib/Horde/Kolab/Server/Test.php" as="Horde/Kolab/Server/Test.php" />
<install name="lib/Horde/Kolab/Server/Test/Search.php" as="Horde/Kolab/Server/Test/Search.php" />
<install name="test/Horde/Kolab/Server/AddingObjectsTest.php" as="Horde/Kolab/Server/AddingObjectsTest.php" />
*
* @return string The corresponding Kolab object type.
*/
- protected function determineType($uid)
+ public function determineType($uid)
{
return 'Horde_Kolab_Server_Object_Kolab_User';
}
/* In the default class we just return an empty array */
return array();
}
+
+ /**
+ * Returns the set of objects supported by this server.
+ *
+ * @return array An array of supported objects.
+ */
+ public function getSupportedObjects()
+ {
+ return array('Horde_Kolab_Server_Object');
+ }
}