Class Sitemap

java.lang.Object
io.goobi.viewer.model.sitemap.Sitemap

public class Sitemap extends Object
Sitemap generation.
  • Constructor Details

    • Sitemap

      public Sitemap()
  • Method Details

    • generate

      public List<File> generate(String viewerRootUrl, String outputPath) throws IOException, PresentationException, IndexUnreachableException, DAOException
      Generates sitemap files and writes them to the given outputPath (or web root).
      Parameters:
      viewerRootUrl - Root URL of the Goobi viewer instance
      outputPath - Destination folder path for the sitemap files.
      Returns:
      File list
      Throws:
      IOException - if any.
      PresentationException - if any.
      IndexUnreachableException - if any.
      DAOException - if any.
    • writeFiles

      protected List<File> writeFiles(String outputDirPath, org.jdom2.Document docIndex, List<org.jdom2.Document> docListSitemap) throws IOException
      Writes givent sitemap XML documents into the file system.
      Parameters:
      outputDirPath - destination directory path for all sitemap files
      docIndex - sitemap index XML document to write
      docListSitemap - list of sitemap XML documents to compress and write
      Returns:
      a list of written sitemap files (index file plus compressed sitemap files)
      Throws:
      IOException - if any.