PHP Class AclExtras, acl_extras

Inheritance: extends Object
Show file Open project: markstory/acl_extras Class Usage Examples

Public Properties

Property Type Description
$Acl AclComponent Contains instance of AclComponent
$args array Contains arguments parsed from the command line.
$dataSource string Contains database source to use
$rootNode string Root node name.

Protected Properties

Property Type Description
$_clean boolean Internal Clean Actions switch

Public Methods

Method Description
aco_sync ( $params = [] ) : void Sync the ACO table
aco_update ( $params = [] ) : void Updates the Aco Tree with new controller actions.
err ( $msg )
getControllerList ( string $plugin = null ) : array Get a list of controllers in the app and plugins.
out ( $msg )
recover ( ) : void Recover an Acl Tree
startup ( $controller = null ) : void Start up And load Acl Component / Aco model
verify ( ) : void Verify a Acl Tree

Protected Methods

Method Description
_checkMethods ( $className, $controllerName, array $node, $pluginPath = false ) : void Check and Add/delete controller Methods
_checkNode ( string $path, string $alias, integer $parentId = null ) : array Check a node for existance, create it if it doesn't exist.
_getCallbacks ( $className ) Get a list of registered callback methods
_updateControllers ( array $root, array $controllers, string $plugin = null ) : void Updates a collection of controllers.

Method Details

_checkMethods() protected method

Check and Add/delete controller Methods
protected _checkMethods ( $className, $controllerName, array $node, $pluginPath = false ) : void
$node array
return void

_checkNode() protected method

Check a node for existance, create it if it doesn't exist.
protected _checkNode ( string $path, string $alias, integer $parentId = null ) : array
$path string
$alias string
$parentId integer
return array Aco Node array

_getCallbacks() protected method

Get a list of registered callback methods
protected _getCallbacks ( $className )

_updateControllers() protected method

Updates a collection of controllers.
protected _updateControllers ( array $root, array $controllers, string $plugin = null ) : void
$root array Array or ACO information for root node.
$controllers array Array of Controllers
$plugin string Name of the plugin you are making controllers for.
return void

aco_sync() public method

Sync the ACO table
public aco_sync ( $params = [] ) : void
return void

aco_update() public method

Updates the Aco Tree with new controller actions.
public aco_update ( $params = [] ) : void
return void

err() public method

public err ( $msg )

getControllerList() public method

Returns an array of path => import notation.
public getControllerList ( string $plugin = null ) : array
$plugin string Name of plugin to get controllers for
return array

out() public method

public out ( $msg )

recover() public method

Recover an Acl Tree
public recover ( ) : void
return void

startup() public method

Start up And load Acl Component / Aco model
public startup ( $controller = null ) : void
return void

verify() public method

Verify a Acl Tree
public verify ( ) : void
return void

Property Details

$Acl public property

Contains instance of AclComponent
public AclComponent $Acl
return AclComponent

$_clean protected property

Internal Clean Actions switch
protected bool $_clean
return boolean

$args public property

Contains arguments parsed from the command line.
public array $args
return array

$dataSource public property

Contains database source to use
public string $dataSource
return string

$rootNode public property

Root node name.
public string $rootNode
return string