Interface Url


@ProviderType public interface Url
A builder-like object that allows to add details to a location added to a Sitemap.
  • Method Details

    • setChangeFrequency

      @NotNull @NotNull Url setChangeFrequency(@NotNull @NotNull Url.ChangeFrequency changeFrequency)
      Sets the change frequency of the url.
      Parameters:
      changeFrequency -
      Returns:
    • setLastModified

      @NotNull @NotNull Url setLastModified(@NotNull @NotNull Instant pointInTime)
      Sets the last modified time of the url.
      Parameters:
      pointInTime -
      Returns:
    • setPriority

      @NotNull @NotNull Url setPriority(double priority)
      Sets the priority of the url. According to the sitemap protocol the priority must be a number between 0.0 and 1.0. Values smaller or greater will be corrected to the lower and upper bound respectively.
      Parameters:
      priority -
      Returns:
    • addExtension

      @Nullable <T extends Extension> T addExtension(Class<T> extensionInterface)
      Adds an extension to the url.
      Type Parameters:
      T - the type of the extension
      Parameters:
      extensionInterface - the interface of the extension to add
      Returns:
      an instance of the given interface, or null when no SitemapExtensionProvider is registered for the given interface