docs: private String getPermissionsCacheKey(CmsObject cms, CmsResource resource) {
  
          try {
              String userName = cms.getRequestContext().getCurrentUser().getName();
              StringBuffer key = new StringBuffer(256);
              key.append(resource.getRootPath()).append("_");
              Iterator<?> itGroups = cms.getGroupsOfUser(userName, true).iterator();
              while (itGroups.hasNext()) {
                  CmsGroup group = (CmsGroup)itGroups.next();
                  key.append(group.getName()).append("_");
              }
              Iterator<?> itRoles = OpenCms.getRoleManager().getRolesOfUser(
                  cms,
                  userName,
                  "",
                  true,
                  true,
                  false).iterator();
              while (itRoles.hasNext()) {
                  CmsRole role = (CmsRole)itRoles.next();
                  key.append(role.getGroupName()).append("_");
              }
              return key.toString();
          } catch (CmsException e) {
              return null;
          }
      }