allow()). * * If a $privilege is not provided, then this method returns false if and only if the * Role is denied access to at least one privilege upon the Resource. In other words, this * method returns true if and only if the Role is allowed all privileges on the Resource. * * This method checks Role inheritance using a depth-first traversal of the Role registry. * The highest priority parent (i.e., the parent most recently added) is checked first, * and its respective parents are checked similarly before the lower-priority parents of * the Role are checked. * * @param Role\RoleInterface|string $role * @param Resource\ResourceInterface|string $resource * @param string $privilege * @return bool */ public function isAllowed($role = null, $resource = null, $privilege = null); }