Overview

Packages

  • Perms

Classes

  • Horde_Perms
  • Horde_Perms_Base
  • Horde_Perms_Datatree
  • Horde_Perms_Exception
  • Horde_Perms_Null
  • Horde_Perms_Permission
  • Horde_Perms_Permission_Datatree
  • Horde_Perms_Permission_Kolab
  • Horde_Perms_Permission_Kolab_Acl
  • Horde_Perms_Permission_Kolab_Acl_Anonymous
  • Horde_Perms_Permission_Kolab_Acl_Anyone
  • Horde_Perms_Permission_Kolab_Acl_Creator
  • Horde_Perms_Permission_Kolab_Acl_Group
  • Horde_Perms_Permission_Kolab_Acl_User
  • Horde_Perms_Permission_Kolab_AclIterator
  • Horde_Perms_Permission_Kolab_Element
  • Horde_Perms_Permission_Kolab_Element_Creator
  • Horde_Perms_Permission_Kolab_Element_Default
  • Horde_Perms_Permission_Kolab_Element_Group
  • Horde_Perms_Permission_Kolab_Element_Guest
  • Horde_Perms_Permission_Kolab_Element_User
  • Horde_Perms_Permission_Kolab_ElementIterator
  • Horde_Perms_Permission_Sql
  • Horde_Perms_Sql
  • Horde_Perms_Translation

Interfaces

  • Horde_Perms_Permission_Kolab_Storage
  • Overview
  • Package
  • Class
  • Tree

Class Horde_Perms_Permission_Datatree

Extension of the Horde_DataTreeObject class for storing Permission information in the Horde_DataTree driver. If you want to store specialized Permission information, you should extend this class instead of extending Horde_DataTreeObject directly.

Horde_DataTreeObject
Extended by Horde_Perms_Permission_Datatree
Package: Perms
Category: Horde
Author: Chuck Hagenbuch chuck@horde.org
Author: Jan Schneider jan@horde.org
Located at Horde/Perms/Permission/Datatree.php
Methods summary
public
# __construct( string $name, string $type = 'matrix', array $params = null )

Constructor. Just makes sure to call the parent constructor so that the perm's name is set properly.

Constructor. Just makes sure to call the parent constructor so that the perm's name is set properly.

Parameters

$name
The name of the perm.
$type
The permission type.
$params
<p>A hash with any parameters that the permission type needs.</p>
public array
# __sleep( )

Don't store cache object on serialize().

Don't store cache object on serialize().

Returns

array
List of variables to serialize.
public
# setCacheOb( Horde_Cache $cache )

Sets the cache instance in the object.

Sets the cache instance in the object.

Parameters

$cache
The cache object.
public mixed
# get( string $attribute )

Gets one of the attributes of the object, or null if it isn't defined.

Gets one of the attributes of the object, or null if it isn't defined.

Parameters

$attribute
The attribute to get.

Returns

mixed
The value of the attribute, or null.
public
# updatePermissions( array $perms )

Updates the permissions based on data passed in the array.

Updates the permissions based on data passed in the array.

Parameters

$perms
<p>An array containing the permissions which are to be updated.</p>
public
# setPerm( mixed $permId, mixed $permission, mixed $update = true )

TODO

TODO

public
# unsetPerm( mixed $permId, mixed $permission, mixed $update = true )

TODO

TODO

public
# addUserPermission( string $user, integer $permission, boolean $update = true )

Grants a user additional permissions to this object.

Grants a user additional permissions to this object.

Parameters

$user
<p>The user to grant additional permissions to.</p>
$permission
The permission (DELETE, etc.) to add.
$update
<p>Whether to automatically update the backend.</p>
public
# addGuestPermission( integer $permission, boolean $update = true )

Grants guests additional permissions to this object.

Grants guests additional permissions to this object.

Parameters

$permission
The permission (DELETE, etc.) to add.
$update
<p>Whether to automatically update the backend.</p>
public
# addCreatorPermission( integer $permission, boolean $update = true )

Grants creators additional permissions to this object.

Grants creators additional permissions to this object.

Parameters

$permission
The permission (DELETE, etc.) to add.
$update
<p>Whether to automatically update the backend.</p>
public
# addDefaultPermission( integer $permission, boolean $update = true )

Grants additional default permissions to this object.

Grants additional default permissions to this object.

Parameters

$permission
The permission (DELETE, etc.) to add.
$update
<p>Whether to automatically update the backend.</p>
public
# addGroupPermission( integer $groupId, integer $permission, boolean $update = true )

Grants a group additional permissions to this object.

Grants a group additional permissions to this object.

Parameters

$groupId
<p>The id of the group to grant additional permissions to.</p>
$permission
The permission (DELETE, etc.) to add.
$update
<p>Whether to automatically update the backend.</p>
public
# removeUserPermission( string $user, integer $permission, boolean $update = true )

Removes a permission that a user currently has on this object.

Removes a permission that a user currently has on this object.

Parameters

$user
The user to remove the permission from.
$permission
<p>The permission (DELETE, etc.) to remove.</p>
$update
<p>Whether to automatically update the backend.</p>
public
# removeGuestPermission( integer $permission, boolean $update = true )

Removes a permission that guests currently have on this object.

Removes a permission that guests currently have on this object.

Parameters

$permission
The permission (DELETE, etc.) to remove.
$update
<p>Whether to automatically update the backend.</p>
public
# removeCreatorPermission( integer $permission, boolean $update = true )

Removes a permission that creators currently have on this object.

Removes a permission that creators currently have on this object.

Parameters

$permission
The permission (DELETE, etc.) to remove.
$update
<p>Whether to automatically update the backend.</p>
public
# removeDefaultPermission( integer $permission, boolean $update = true )

Removes a default permission on this object.

Removes a default permission on this object.

Parameters

$permission
The permission (DELETE, etc.) to remove.
$update
<p>Whether to automatically update the backend.</p>
public
# removeGroupPermission( integer $groupId, integer $permission, boolean $update = true )

Removes a permission that a group currently has on this object.

Removes a permission that a group currently has on this object.

Parameters

$groupId
<p>The id of the group to remove the permission from.</p>
$permission
The permission (DELETE, etc.) to remove.
$update
<p>Whether to automatically update the backend.</p>
public array
# getUserPermissions( integer $perm = null )

Returns an array of all user permissions on this object.

Returns an array of all user permissions on this object.

Parameters

$perm
<p>List only users with this permission level. Defaults to all users.</p>

Returns

array
All user permissions for this object, indexed by user.
public integer
# getGuestPermissions( )

Returns the guest permissions on this object.

Returns the guest permissions on this object.

Returns

integer
The guest permissions on this object.
public integer
# getCreatorPermissions( )

Returns the creator permissions on this object.

Returns the creator permissions on this object.

Returns

integer
The creator permissions on this object.
public integer
# getDefaultPermissions( )

Returns the default permissions on this object.

Returns the default permissions on this object.

Returns

integer
The default permissions on this object.
public array
# getGroupPermissions( integer $perm = null )

Returns an array of all group permissions on this object.

Returns an array of all group permissions on this object.

Parameters

$perm
<p>List only users with this permission level. Defaults to all users.</p>

Returns

array
All group permissions for this object, indexed by group.
public
# save( )

Saves any changes to this object to the backend permanently. New objects are added instead.

Saves any changes to this object to the backend permanently. New objects are added instead.

Throws

Horde_Perms_Exception
API documentation generated by ApiGen