Package org.apache.sling.sitemap.builder
Interface Url
A builder-like object that allows to add details to a location added to a
Sitemap
.-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescription<T extends Extension>
TaddExtension
(Class<T> extensionInterface) Adds an extension to the url.@NotNull Url
setChangeFrequency
(@NotNull Url.ChangeFrequency changeFrequency) Sets the change frequency of the url.@NotNull Url
setLastModified
(@NotNull Instant pointInTime) Sets the last modified time of the url.@NotNull Url
setPriority
(double priority) Sets the priority of the url.
-
Method Details
-
setChangeFrequency
Sets the change frequency of the url.- Parameters:
changeFrequency
-- Returns:
-
setLastModified
Sets the last modified time of the url.- Parameters:
pointInTime
-- Returns:
-
setPriority
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
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
-