code: protected CmsPublishData getPublishData(CmsProject project, List<CmsResource> directPublishResources) {
  
          CmsPublishService publishService = new CmsPublishService();
          CmsObject cms = A_CmsUI.getCmsObject();
          publishService.setCms(cms);
          List<String> pathList = new ArrayList<String>();
          if (directPublishResources != null) {
              for (CmsResource resource : directPublishResources) {
                  pathList.add(cms.getSitePath(resource));
              }
          }
          publishService.setRequest((HttpServletRequest)(VaadinService.getCurrentRequest()));
          try {
              return publishService.getPublishData(
                  cms,
                  new HashMap<String, String>()/*params*/,
                  null/*workflowId*/,
                  project != null ? project.getUuid().toString() : null /*projectParam*/,
                  pathList,
                  null/*closelink*/,
                  false/*confirmation*/);
          } catch (Exception e) {
              LOG.error(e.getLocalizedMessage(), e);
              return null;
          }
      }
docs: Gets the publish data for the given resources.<p>
  
  @param directPublishResources the resources to publish
  @param project the project for which to open the dialog
  
  @return the publish data for the resources