Author: Ben Chavet (ben@horde.org)
Author: Jan Schneider (jan@horde.org)
Inheritance: extends Horde_Group_Base
Example #1
0
 /**
  * Creates a new group.
  *
  * @param string $name   A group name.
  * @param string $email  The group's email address.
  *
  * @return mixed  The ID of the created group.
  * @throws Horde_Group_Exception
  */
 public function create($name, $email = null)
 {
     try {
         return $this->_create($name, $GLOBALS['injector']->getInstance('Horde_Core_Hooks')->callHook('groupldap', 'horde', array($name, $email)));
     } catch (Horde_Exception_HookNotSet $e) {
         return parent::create($name, $email);
     }
 }
Example #2
0
 /**
  * Returns a list of groups a user belongs to.
  *
  * @param string $user  A user name.
  *
  * @return array  A list of groups, with IDs as keys and names as values.
  * @throws Horde_Group_Exception
  */
 public function listGroups($user)
 {
     return parent::listGroups($this->_dnForMail($user));
 }