protected function searchParentResourceACEs($roleId, $resourceId, $permissionId, array $params = array(), $level = 0)
    {
        $allowedAny = null;
        if (isset($this->resourcesParents[$resourceId]) && isset($this->roles[$roleId]) && isset($this->permissions[$permissionId])) {
            if (isset($this->logger)) {
                $this->logger->addRecord(Logger::DEBUG, sprintf("%sChecking if specified role has specified permission to any parent resource",
                    str_repeat('  ', $level)
                ));
            }
            foreach ($this->resourcesParents[$resourceId] as $parentResourceId => $parentResource) {
                $allowed = $this->searchACEs($roleId, $parentResourceId, $permissionId, $params, $level + 1);
                if (!isset($allowed)) {
                    $allowed = $this->searchParentResourceACEs($roleId, $parentResourceId, $permissionId, $params, $level + 1);
                }
                if (isset($allowed)) {
                    if (!$allowed) {
                        return $allowed;
                    } else {
                        $allowedAny = true;
                    }
                }
            }
        }
        return $allowedAny;
    }