Class Perms_datatree

Description

The Perms_datatree:: class provides a DataTree driver for the Horde permissions system.

$Horde: framework/Perms/Perms/datatree.php,v 1.6.2.24 2009/08/14 21:45:52 jan Exp $

Copyright 2001-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.

Located in /Perms/Perms/datatree.php (line 22)

Perms
   |
   --Perms_datatree
Variable Summary
Method Summary
 Perms_datatree Perms_datatree ()
 void addPermission ( &$perm, DataTreeObject_Permission $perm)
 boolean exists (string $permission)
 mixed getParent (mixed $child)
 array getParents (string $child)
 void &getPermission (string $name)
 void &getPermissionById (integer $cid)
 array &getTree ()
 DataTreeObject_Permissions &newPermission (string $name)
 void removePermission ( &$perm, [boolean $force = false], DataTreeObject_Permission $perm)
Variables
Horde_Cache $_cache (line 37)

Pointer to a Horde_Cache instance

DataTree $_datatree (line 30)

Pointer to a DataTree instance to manage the different permissions.

Inherited Variables

Inherited from Perms

Perms::$_applicationPermissions
Methods
Constructor Perms_datatree (line 42)

Constructor.

Perms_datatree Perms_datatree ()
addPermission (line 139)

Adds a permission to the permissions system. The permission must first be created with Perm::newPermission(), and have any initial users added to it, before this function is called.

void addPermission ( &$perm, DataTreeObject_Permission $perm)

Redefinition of:
Perms::addPermission()
Adds a permission to the permissions system. The permission must first be created with Perm::newPermission(), and have any initial users added to it, before this function is called.
exists (line 196)

Checks if a permission exists in the system.

  • return: True if the permission exists.
boolean exists (string $permission)
  • string $permission: The permission to check.

Redefinition of:
Perms::exists()
Checks if a permission exists in the system.
getParent (line 229)

Returns a child's direct parent ID.

  • return: The unique ID of the parent or PEAR_Error on error.
mixed getParent (mixed $child)
  • mixed $child: Either the object, an array containing the path elements, or the object name for which to look up the parent's ID.
getParents (line 215)

Returns a list of parent permissions.

  • return: A hash with all parents in a tree format.
array getParents (string $child)
  • string $child: The name of the child to retrieve parents for.

Redefinition of:
Perms::getParents()
Returns a list of parent permissions.
getPermission (line 95)

Returns a DataTreeObject_Permission object corresponding to the named permission, with the users and other data retrieved appropriately.

void &getPermission (string $name)
  • string $name: The name of the permission to retrieve.

Redefinition of:
Perms::getPermission()
Returns a Permission object corresponding to the named permission, with the users and other data retrieved appropriately.
getPermissionById (line 122)

Returns a DataTreeObject_Permission object corresponding to the given unique ID, with the users and other data retrieved appropriately.

void &getPermissionById (integer $cid)
  • integer $cid: The unique ID of the permission to retrieve.

Redefinition of:
Perms::getPermissionById()
Returns a Permission object corresponding to the given unique ID, with the users and other data retrieved appropriately.
getPermissionId (line 184)

Returns the unique identifier of this permission.

  • return: The unique id.
integer getPermissionId (DataTreeObject_Permission $permission)

Redefinition of:
Perms::getPermissionId()
Returns the unique identifier of this permission.
getTree (line 239)

Returns all permissions of the system in a tree format.

  • return: A hash with all permissions in a tree format.
array &getTree ()

Redefinition of:
Perms::getTree()
Returns all permissions of the system in a tree format.
newPermission (line 66)

Returns a new permissions object.

  • return: A new permissions object.
DataTreeObject_Permissions &newPermission (string $name)
  • string $name: The permission's name.

Redefinition of:
Perms::newPermission()
Returns a new permissions object.
removePermission (line 161)

Removes a permission from the permissions system permanently.

void removePermission ( &$perm, [boolean $force = false], DataTreeObject_Permission $perm)

Redefinition of:
Perms::removePermission()
Removes a permission from the permissions system permanently.

Inherited Methods

Inherited From Perms

 Perms::addPermission()
 Perms::exists()
 Perms::factory()
 Perms::getApplicationPermissions()
 Perms::getAvailable()
 Perms::getParents()
 Perms::getPermission()
 Perms::getPermissionById()
 Perms::getPermissionId()
 Perms::getPermissions()
 Perms::getPermsArray()
 Perms::getShortName()
 Perms::getTitle()
 Perms::getTree()
 Perms::hasPermission()
 Perms::integerToArray()
 Perms::newPermission()
 Perms::removePermission()
 Perms::singleton()

Documentation generated on Sun, 30 Jan 2011 05:16:31 +0000 by phpDocumentor 1.4.3