Definition at line 14 of file Acl.php.
◆ __construct()
- Parameters
-
Definition at line 24 of file Acl.php.
26 $this->_aclBuilder = $aclBuilder;
◆ isAllowed()
isAllowed |
( |
|
$roleId, |
|
|
|
$resourceId, |
|
|
|
$privilege = null |
|
) |
| |
Check whether given role has access to give id
- Parameters
-
string | $roleId | |
string | $resourceId | |
string | $privilege | |
- Returns
- bool
Implements PolicyInterface.
Definition at line 37 of file Acl.php.
40 return $this->_aclBuilder->getAcl()->isAllowed(
$roleId, $resourceId, $privilege);
41 }
catch (\Exception $e) {
43 if (!$this->_aclBuilder->getAcl()->has($resourceId)) {
44 return $this->_aclBuilder->getAcl()->isAllowed(
$roleId,
null, $privilege);
46 }
catch (\Exception $e) {
◆ $_aclBuilder
The documentation for this class was generated from the following file:
- vendor/magento/framework/Authorization/Policy/Acl.php