Methods

__construct()

__construct(string $name) 

Parameters

$name

string

Add a child.

addChild(\Zend\Permissions\Rbac\RoleInterface | string $child) : \Zend\Permissions\Rbac\Role
Inherited

inherited_from \Zend\Permissions\Rbac\AbstractRole::addChild()

Parameters

Returns

Add permission to the role.

addPermission($name) : \Zend\Permissions\Rbac\RoleInterface
Inherited

inherited_from \Zend\Permissions\Rbac\AbstractRole::addPermission()

Parameters

$name

Returns

(PHP 5 &gt;= 5.0.0)<br/> Return the current element

current() : mixed
Inherited

link http://php.net/manual/en/iterator.current.php
inherited_from \Zend\Permissions\Rbac\AbstractIterator::current()
inherited_from \Zend\Permissions\Rbac\AbstractRole::current()

Returns

mixedCan return any type.

(PHP 5 &gt;= 5.1.0)<br/> Returns an iterator for the current entry.

getChildren() : \RecursiveIterator
Inherited

link http://php.net/manual/en/recursiveiterator.getRoles.php
inherited_from \Zend\Permissions\Rbac\AbstractIterator::getChildren()
inherited_from \Zend\Permissions\Rbac\AbstractRole::getChildren()

Returns

\RecursiveIteratorAn iterator for the current entry.

Get the name of the role.

getName() : string
Inherited

inherited_from \Zend\Permissions\Rbac\AbstractRole::getName()

Returns

string

getParent()

getParent() : null | \Zend\Permissions\Rbac\RoleInterface
Inherited

inherited_from \Zend\Permissions\Rbac\AbstractRole::getParent()

Returns

(PHP 5 &gt;= 5.1.0)<br/> Returns if an iterator can be created fot the current entry.

hasChildren() : bool
Inherited

link http://php.net/manual/en/recursiveiterator.haschildren.php
inherited_from \Zend\Permissions\Rbac\AbstractIterator::hasChildren()
inherited_from \Zend\Permissions\Rbac\AbstractRole::hasChildren()

Returns

booltrue if the current entry can be iterated over, otherwise returns false.

Checks if a permission exists for this role or any child roles.

hasPermission(string $name) : bool
Inherited

inherited_from \Zend\Permissions\Rbac\AbstractRole::hasPermission()

Parameters

$name

string

Returns

bool

(PHP 5 &gt;= 5.0.0)<br/> Return the key of the current element

key() : \Zend\Permissions\Rbac\scalar
Inherited

link http://php.net/manual/en/iterator.key.php
inherited_from \Zend\Permissions\Rbac\AbstractIterator::key()
inherited_from \Zend\Permissions\Rbac\AbstractRole::key()

Returns

\Zend\Permissions\Rbac\scalarscalar on success, or null on failure.

(PHP 5 &gt;= 5.0.0)<br/> Rewind the Iterator to the first element

rewind() : void
Inherited

link http://php.net/manual/en/iterator.rewind.php
inherited_from \Zend\Permissions\Rbac\AbstractIterator::rewind()
inherited_from \Zend\Permissions\Rbac\AbstractRole::rewind()

setParent()

setParent(\Zend\Permissions\Rbac\RoleInterface $parent) : \Zend\Permissions\Rbac\RoleInterface
Inherited

inherited_from \Zend\Permissions\Rbac\AbstractRole::setParent()

Parameters

Returns

(PHP 5 &gt;= 5.0.0)<br/> Checks if current position is valid

valid() : boolean
Inherited

link http://php.net/manual/en/iterator.valid.php
inherited_from \Zend\Permissions\Rbac\AbstractIterator::valid()
inherited_from \Zend\Permissions\Rbac\AbstractRole::valid()

Returns

booleanThe return value will be casted to boolean and then evaluated. Returns true on success or false on failure.

 Properties

 

$children

$children 
Inherited

inherited_from \Zend\Permissions\Rbac\AbstractIterator::$$children
inherited_from \Zend\Permissions\Rbac\AbstractRole::$$children
 

$index

$index 
Inherited

inherited_from \Zend\Permissions\Rbac\AbstractIterator::$$index
inherited_from \Zend\Permissions\Rbac\AbstractRole::$$index
 

$name

$name : string
Inherited

inherited_from \Zend\Permissions\Rbac\AbstractRole::$$name
 

$parent

$parent : null | \Zend\Permissions\Rbac\RoleInterface
Inherited

inherited_from \Zend\Permissions\Rbac\AbstractRole::$$parent
 

$permissions

$permissions : array
Inherited

inherited_from \Zend\Permissions\Rbac\AbstractRole::$$permissions