[ Index ]

PHP Cross Reference of ACL Module

title

Body

[close]

/components/strategies/nestedSet/pathMaterialization/models/ -> PmAclObject.php (summary)

(no description)

File Size: 305 lines (11 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

PmAclObject:: (12 methods):
  getFreeNodes()
  getPaths()
  buildTreeQueryCondition()
  fetchComprisedPositions()
  addPositionCheck()
  createNode()
  getDirectChildNodes()
  getDirectParentNodes()
  beforeDelete()
  join()
  leave()
  is()


Class: PmAclObject  - X-Ref

The specialization of the general AclObject.
This class implements the path-materialization-specific/optimized position-
and rights-operations

getFreeNodes()   X-Ref
Returns all of the AclNodes of this object which do not have a parent yet

param: AclObject object
return: array[AclNode]

getPaths()   X-Ref
Fetches all Paths of the nodes of this object

return: array[string] the paths of the nodes

buildTreeQueryCondition($source, $destination, $disableInheritance = false)   X-Ref
Builds (string) condition which matches all destinations, which are children
of source
field should be either aco or aro

param: array $source array('field' => '', 'table' => '')
param: array $destination array('field' => '', 'table' => '')
param: boolean   $disableInheritance if set to true, no inheritance will be used, that means no node will acquire the rights of it's parent

fetchComprisedPositions()   X-Ref
Fetches and returns positions of all nodes of this object
which denote them
In this case, it's really easy because we've done that anyway :)

return: array[string]

addPositionCheck($positions, $type, $table = 't')   X-Ref
Builds a single SQL-statement comprising all given positions and their parents
This SQL-statement will match all those rows being located above the given positions including themselves

param: array $positions All positions to include in our statement
param: string $type aco/aro
param: string $table the table comprising the map between objects and permissions
return: string the finished SQL-statement

createNode($parent = NULL)   X-Ref
Creates a new node of this collection
This new node will be a children of the given AclNode

param: AclNode $parent  parent of the new node, if NULL, it has no parent
return: AclNode the new node

getDirectChildNodes(AclObject $child = NULL)   X-Ref
Returns all of the (direct) AclNodes whose parent AclNode is a node of this
AclObject.

If the $child AclObject is specified, only nodes having the given AclObject
as owner will be returned.

param: AclObject child
param: Integer
return: array[AclNode]

getDirectParentNodes(AclObject $parent = NULL)   X-Ref
Returns all of the (direct) AclNodes whose child AclNode is a node of this
AclObject.

If the $child AclObject is specified, only nodes having the given AclObject
as owner will be returned.

param: AclObject child
param: Integer
return: array[AclNode]

beforeDelete()   X-Ref
Processes post-deletion tasks


join($obj)   X-Ref
Joins the given object (now called: group)

param: mixed $obj
return: boolean

leave($obj)   X-Ref
Leaves the given group

param: mixed $obj
return: boolean

is($obj)   X-Ref
Checks whether this object is somehow a child of the given object

param: mixed $obj
return: boolean



Generated: Sun Jul 1 19:24:45 2012 Cross-referenced by PHPXref 0.7.1