function RulesAbstractPlugin::access
Whether the currently logged in user has access to all configured elements.
Note that this only checks whether the current user has permission to all configured elements, but not whether a user has access to configure Rule configurations in general. Use rules_config_access() for that.
Use this to determine access permissions for configuring or triggering the execution of certain configurations independent of the Rules UI.
Overrides RulesPlugin::access
File
-
includes/
rules.core.inc, line 1591
Class
- RulesAbstractPlugin
- Defines a common base class for so-called "Abstract Plugins" like actions.
Code
public function access() {
$info = $this->info();
$this->loadBasicInclude();
if (!empty($info['access callback']) && !call_user_func($info['access callback'], $this->itemName, $this->getElementName())) {
return FALSE;
}
return parent::access() && $this->__call('access');
}