PHP Class ZfcRbac\Guard\RouteGuard

Author: Michaël Gallego ([email protected])
Inheritance: extends AbstractGuard, use trait ProtectionPolicyTrait
Afficher le fichier Open project: zf-commons/zfc-rbac Class Usage Examples

Protected Properties

Свойство Type Description
$roleService ZfcRbac\Service\RoleService
$rules array Those rules are an associative array that map a rule with one or multiple roles

Méthodes publiques

Méthode Description
__construct ( RoleService $roleService, array $rules = [] ) Constructor
isGranted ( MvcEvent $event ) {@inheritDoc}
setRules ( array $rules ) : void Set the rules (it overrides any existing rules)

Method Details

__construct() public méthode

Constructor
public __construct ( RoleService $roleService, array $rules = [] )
$roleService ZfcRbac\Service\RoleService
$rules array

isGranted() public méthode

{@inheritDoc}
public isGranted ( MvcEvent $event )
$event Zend\Mvc\MvcEvent

setRules() public méthode

Set the rules (it overrides any existing rules)
public setRules ( array $rules ) : void
$rules array
Résultat void

Property Details

$roleService protected_oe property

protected RoleService,ZfcRbac\Service $roleService
Résultat ZfcRbac\Service\RoleService

$rules protected_oe property

Those rules are an associative array that map a rule with one or multiple roles
protected array $rules
Résultat array