Class SitemapGenerator

    • Constructor Detail

      • SitemapGenerator

        public SitemapGenerator​(String baseUrl)
        This constructor is public, because sometimes somebody wants SitemapGenerator to be a Spring bean and Spring wants to create a proxy which requires public constructor. But you shouldn't call this constructor on your own, use of(String) instead.
        Parameters:
        baseUrl - Base URL
    • Method Detail

      • of

        public static SitemapGenerator of​(String baseUrl)
        Helper method to create an instance of SitemapGenerator
        Parameters:
        baseUrl - Base URL
        Returns:
        Instance of SitemapGenerator
      • toStringArray

        public String[] toStringArray()
        Construct sitemap into array of Strings. The URLs will be ordered using priority in descending order (URLs with higher priority will be at the top).
        Specified by:
        toStringArray in class AbstractSitemapGenerator<SitemapGenerator>
        Returns:
        sitemap
      • constructImage

        protected String constructImage​(Image image)
      • constructUrl

        protected String constructUrl​(WebPage webPage)