/** * @see org.opencms.staticexport.I_CmsStaticExportHandler#performEventPublishProject(org.opencms.util.CmsUUID, org.opencms.report.I_CmsReport) */ @Override public void performEventPublishProject(CmsUUID publishHistoryId, I_CmsReport report) { try { m_busy = true; exportAfterPublish(publishHistoryId, report); } catch (Throwable t) { if (LOG.isErrorEnabled()) { LOG.error(Messages.get().getBundle().key(Messages.LOG_STATIC_EXPORT_ERROR_0), t); } if (report != null) { report.addError(t); } } finally { m_busy = false; } }
List<CmsPublishedResource> resourcesToExport = getRelatedResources(cmsExportObject, resources); templatesFound = exportNonTemplateResources(cmsExportObject, resourcesToExport, report); LOG.warn("finished exporting non-template resources. "); exportTemplateResources(cmsExportObject, publishedTemplateResources, report);
/** * Returns all siblings of the published resource as list of <code>CmsPublishedResource</code>.<p> * * @param cms the cms object * @param pubResource the published resource * * @return all siblings of the published resource * * @throws CmsException if something goes wrong */ protected Set getSiblings(CmsObject cms, CmsPublishedResource pubResource) throws CmsException { Set siblings = new HashSet(); for (Iterator i = getSiblingsList(cms, pubResource.getRootPath()).iterator(); i.hasNext();) { String sibling = (String)i.next(); siblings.add(new CmsPublishedResource(cms.readResource(sibling))); } return siblings; }
List publishedResources = scrubExportFolders(publishHistoryId); doExportAfterPublish(publishedResources, report);
CmsAfterPublishStaticExportHandler handler = new CmsAfterPublishStaticExportHandler(); handler.doExportAfterPublish(null, report);
if (publishedResources == null) { return getAllResources(cms); } else { Iterator<CmsPublishedResource> itSiblings = getSiblings(cms, pubResource).iterator(); while (itSiblings.hasNext()) { CmsPublishedResource sibling = itSiblings.next(); return getAllResources(cms);
int status = exportTemplateResource(rfsName, vfsName, cookies);
List<CmsPublishedResource> publishedResources = scrubExportFolders(publishHistoryId); doExportAfterPublish(publishedResources, report);
CmsAfterPublishStaticExportHandler handler = new CmsAfterPublishStaticExportHandler(); handler.doExportAfterPublish(null, report);
if (publishedResources == null) { return getAllResources(cms); } else { Iterator itSiblings = getSiblings(cms, pubResource).iterator(); while (itSiblings.hasNext()) { CmsPublishedResource sibling = (CmsPublishedResource)itSiblings.next(); return getAllResources(cms);
data.getResource(), data.getParameters()); exportTemplateResource(detailData, cookies); int status = exportTemplateResource(data, cookies);
List resourcesToExport = getRelatedResources(cmsExportObject, resources); templatesFound = exportNonTemplateResources(cmsExportObject, resourcesToExport, report); exportTemplateResources(cmsExportObject, publishedTemplateResources, report);
/** * Returns all siblings of the published resource as list of <code>CmsPublishedResource</code>.<p> * * @param cms the cms object * @param pubResource the published resource * * @return all siblings of the published resource * * @throws CmsException if something goes wrong */ protected Set<CmsPublishedResource> getSiblings(CmsObject cms, CmsPublishedResource pubResource) throws CmsException { Set<CmsPublishedResource> siblings = new HashSet<CmsPublishedResource>(); for (Iterator<String> i = getSiblingsList(cms, pubResource.getRootPath()).iterator(); i.hasNext();) { String sibling = i.next(); siblings.add(new CmsPublishedResource(cms.readResource(sibling))); } return siblings; }
/** * @see org.opencms.staticexport.I_CmsStaticExportHandler#performEventPublishProject(org.opencms.util.CmsUUID, org.opencms.report.I_CmsReport) */ @Override public void performEventPublishProject(CmsUUID publishHistoryId, I_CmsReport report) { try { m_busy = true; exportAfterPublish(publishHistoryId, report); } catch (Throwable t) { if (LOG.isErrorEnabled()) { LOG.error(Messages.get().getBundle().key(Messages.LOG_STATIC_EXPORT_ERROR_0), t); } if (report != null) { report.addError(t); } } finally { m_busy = false; } }