Class CAuthItem
CAuthItem represents an authorization item. An authorization item can be an operation, a task or a role. They form an authorization hierarchy. Items on higher levels of the hierarchy inherit the permissions represented by items on lower levels. A user may be assigned one or several authorization items (called CAuthAssignment assignments. He can perform an operation only when it is among his assigned items.
- CComponent
- CAuthItem
Copyright: 2008-2013 Yii Software LLC
License: http://www.yiiframework.com/license/
Author: Qiang Xue <qiang.xue@gmail.com>
Since: 1.0
Located at x2engine/framework/web/auth/CAuthItem.php
public
|
#
__construct(
Constructor. |
public
boolean
|
#
checkAccess( string $itemName, array $params = array() )
Checks to see if the specified item is within the hierarchy starting from
this item. This method is expected to be internally used by the actual
implementations of the |
public
|
|
public
integer
|
|
public
string
|
|
public
|
|
public
string
|
|
public
|
|
public
string
|
|
public
|
|
public
mixed
|
|
public
|
|
public
boolean
|
|
public
boolean
|
#
removeChild( string $name )
Removes a child item. Note, the child item is not deleted. Only the parent-child relationship is removed. |
public
boolean
|
|
public
array
|
|
public
|
|
public
boolean
|
|
public
boolean
|
#
isAssigned( mixed $userId )
Returns a value indicating whether this item has been assigned to the user. |
public
|
integer |
TYPE_OPERATION
|
0 |
|
integer |
TYPE_TASK
|
1 |
|
integer |
TYPE_ROLE
|
2 |
public
|
$authManager |
#
The authorization manager. |
public
integer
|
$type |
#
The authorization item type. This could be 0 (operation), 1 (task) or 2 (role). |
public
string
|
$name |
#
The item name. |
public
string
|
$description |
#
The item description. |
public
string
|
$bizRule |
#
The business rule associated with this item. |
public
mixed
|
$data |
#
The additional data associated with this item. |
public
array
|
$children |
#
All child items of this item. |