Commit a5b988e3 authored by Ate Douma's avatar Ate Douma

HIPPLUG-970: initial import of the sitemap standard plugin for CMS 7.10,...

HIPPLUG-970: initial import of the sitemap standard plugin for CMS 7.10, cloned (unmodified) from the Forge sitemap plugin
parents
* text=auto !eol
/LICENSE -text
/NOTICE -text
component/pom.xml svneol=native#text/plain
content/pom.xml svneol=native#text/plain
content/src/main/resources/component.xml svneol=native#text/plain
content/src/main/resources/hippoecm-extension.xml svneol=native#text/plain
content/src/main/resources/news-sitemap-component.xml svneol=native#text/plain
content/src/main/resources/sitemap-based-on-hst-sitemap-component.xml svneol=native#text/plain
content/src/main/resources/sitemap-entry.xml svneol=native#text/plain
content/src/main/resources/sitemap-index-component.xml svneol=native#text/plain
content/src/main/resources/template.xml svneol=native#text/plain
/pom.xml svneol=native#text/plain
src/site/resources/sitemapxml.jpg -text svneol=unset#image/jpeg
src/site/site.xml svneol=native#text/plain
src/site/xdoc/basicsitemap.xml svneol=native#text/plain
src/site/xdoc/build-demo.xml svneol=native#text/plain
src/site/xdoc/hstsitemapcrawler.xml svneol=native#text/plain
src/site/xdoc/index.xml svneol=native#text/plain
src/site/xdoc/newssitemap.xml svneol=native#text/plain
src/site/xdoc/release-notes.xml svneol=native#text/plain
src/site/xdoc/sitemapindex.xml svneol=native#text/plain
src/site/xdoc/usage.xml svneol=native#text/plain
This diff is collapsed.
Hippo Forge Sitemap Component
Copyright 2009-2014 Hippo B.V. (http://www.onehippo.com)
This product includes software developed by:
Hippo B.V., Amsterdam, The Netherlands (http://www.onehippo.com/);
The Apache Software Foundation (http://www.apache.org/).
NOTICE: Only our own original work is licensed under the terms of the
Apache License Version 2.0. The licenses of some libraries might impose
different redistribution or general licensing terms than those stated in the
Apache License. Users and redistributors are hereby requested to verify these
conditions and agree upon them.
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright 2010-2014 Hippo B.V. (http://www.onehippo.com)
Licensed under the Apache License,
Version 2.0 (the "License"); you may not use this file except in
compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under
the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES
OR CONDITIONS OF ANY KIND, either express or implied. See the
License for the specific language governing permissions and
limitations under the License.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.onehippo.forge.sitemap</groupId>
<artifactId>sitemap</artifactId>
<version>1.07.00-SNAPSHOT</version>
</parent>
<name>Hippo Forge Sitemap HST Component</name>
<description>Hippo Forge Sitemap HST Component</description>
<artifactId>sitemap-component</artifactId>
<packaging>jar</packaging>
<dependencies>
<dependency>
<groupId>org.onehippo.cms7.hst.dependencies</groupId>
<artifactId>hst-client-dependencies</artifactId>
<version>${hippo.hst.version}</version>
<scope>provided</scope>
<type>pom</type>
</dependency>
<dependency>
<groupId>org.onehippo.cms7.hst</groupId>
<artifactId>hst-api</artifactId>
<version>${hippo.hst.version}</version>
<scope>provided</scope>
<!-- <type>pom</type> -->
</dependency>
<dependency>
<groupId>org.onehippo.cms7.hst</groupId>
<artifactId>hst-commons</artifactId>
<version>${hippo.hst.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.4</version>
<scope>test</scope>
</dependency>
<!-- For HippoNodeType constants -->
<dependency>
<groupId>org.onehippo.cms7</groupId>
<artifactId>hippo-repository-api</artifactId>
<version>${hippo.repository.version}</version>
<scope>provided</scope>
</dependency>
<!-- For HippoStdNodeType constants -->
<dependency>
<groupId>org.onehippo.cms7</groupId>
<artifactId>hippo-repository-builtin</artifactId>
<version>${hippo.repository.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.onehippo.cms7.hst.components</groupId>
<artifactId>hst-jaxrs</artifactId>
<version>${hippo.hst.version}</version>
<scope>provided</scope>
</dependency>
<!-- Warning: Sun/Oracle specific (provided) dependency: assumes com.sun.xml.bind.marshaller.CharacterEscapeHandler
is available on the classpath (from the rt.jar), which is Sun/Oracle Java specific -->
<!-- Include a newer version of the JAXB implementation, so that namespace prefixes are propertly rendered -->
<dependency>
<groupId>com.sun.xml.bind</groupId>
<artifactId>jaxb-impl</artifactId>
<version>${com-sun-jaxb-impl.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-compress</artifactId>
<version>${commons-compress.version}</version>
</dependency>
<!-- needed for @Required annotation -->
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-beans</artifactId>
<version>${spring.version}</version>
<scope>provided</scope>
</dependency>
</dependencies>
<build>
<defaultGoal>package</defaultGoal>
</build>
</project>
/*
* Copyright 2012-2013 Hippo B.V. (http://www.onehippo.com)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.onehippo.forge.sitemap.components;
import org.hippoecm.hst.content.beans.standard.HippoBean;
import org.onehippo.forge.sitemap.components.model.news.info.AccessType;
import org.onehippo.forge.sitemap.components.model.news.info.Genre;
import org.onehippo.forge.sitemap.components.model.news.info.Publication;
import java.util.Calendar;
import java.util.List;
/**
* An interface implemented by classes that can resolve news sitemap item properties for HippoBeans
* Classes that implement this interface can be passed to the SitemapGenerator to be used in creating a news site map.
*
* @author Wouter Danes
*/
public interface NewsInformationProvider extends UrlInformationProvider{
/**
* Returns a comma seperated list of geo locations for this sitemap item, from more to less specific, f.ex:
* Amsterdam, Netherlands, Europe
* @param hippoBean the document to generate the geo locations value for
* @return {@link String} containing a comma seperated list of geo locations
*/
String getGeoLocations(HippoBean hippoBean);
/**
* Returns the title of the document for the google news sitemap
* @param hippoBean the document to generate the title value for
* @return {@link String} containing the Title of this news document
*/
String getTitle(HippoBean hippoBean);
/**
* Returns the access type of this news document. For a list of supported values, check the {@link AccessType} enum.
* @param hippoBean the document to return the {@link AccessType} for
* @return the {@link AccessType} for this news document
*/
AccessType getAccess(HippoBean hippoBean);
/**
* Returns the {@link Publication} for this news document
* @param hippoBean the document to return the {@link Publication} for
* @return the {@link Publication} for this news document
*/
Publication getPublication(HippoBean hippoBean);
/**
* Returns the publication date for the passed {@link HippoBean}.
* @param hippoBean the document to return the publication date for
* @return {@link Calendar} representing the publication date of this news document
*/
Calendar getPublicationDate(HippoBean hippoBean);
/**
* Returns the {@link Genre}s for the passed {@link HippoBean}
* @param hippoBean the document to return the {@link Genre}s for. For possible values check the enum.
* @return {@link List} containing the applicable {@link Genre}s.
*/
List<Genre> getGenres(HippoBean hippoBean);
/**
* Returns a comma seperated list of keywords that are applicable to the passed {@link HippoBean}
* @param hippoBean the document to return the keywords for.
* @return a {@link String} containing a comma seperated list of keywords
*/
List<String> getKeywords(HippoBean hippoBean);
/**
* Returns the publication date property that will be used to resolve the age of documents. documents old than 48
* hours should not be included in the news sitemap
* @return the name of the property of type jcr:date that contains the publication date of a news document
*/
String getPublicationDateProperty();
}
/*
* Copyright 2012-2013 Hippo B.V. (http://www.onehippo.com)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.onehippo.forge.sitemap.components;
import static org.onehippo.forge.sitemap.components.util.ReflectionUtils.obtainInstanceForClass;
import java.util.Calendar;
import java.util.Collections;
import java.util.GregorianCalendar;
import java.util.HashMap;
import java.util.Map;
import java.util.TimeZone;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
import org.apache.commons.lang.StringUtils;
import org.hippoecm.hst.component.support.bean.BaseHstComponent;
import org.hippoecm.hst.container.RequestContextProvider;
import org.hippoecm.hst.content.beans.query.HstQuery;
import org.hippoecm.hst.content.beans.query.exceptions.QueryException;
import org.hippoecm.hst.content.beans.query.filter.Filter;
import org.hippoecm.hst.content.beans.standard.HippoBean;
import org.hippoecm.hst.core.component.HstComponentException;
import org.hippoecm.hst.core.component.HstRequest;
import org.hippoecm.hst.core.component.HstResponse;
import org.hippoecm.hst.core.parameters.Parameter;
import org.hippoecm.hst.core.parameters.ParametersInfo;
import org.hippoecm.hst.core.request.HstRequestContext;
import org.onehippo.forge.sitemap.components.model.news.NewsUrlset;
import org.onehippo.forge.sitemap.components.model.news.info.Publication;
import org.onehippo.forge.sitemap.generator.DefaultNewsInformationProvider;
import org.onehippo.forge.sitemap.generator.NewsSitemapGenerator;
/**
* This component serves a news sitemap based on configured document types
* The documents in the news sitemap cannot be older than 48 hours
* This class uses deprecated annotations and methods to be compatible with Hippo 7.6
*
* @author Wouter Danes
*/
@SuppressWarnings({"unused"})
@ParametersInfo(type = NewsSitemapFeed.NewsSitemapFeedParametersInformation.class)
public class NewsSitemapFeed extends BaseHstComponent {
private static final int MAX_AGE_IN_HOURS = 48;
public interface NewsSitemapFeedParametersInformation {
@Parameter(
name = "publicationDateProperty",
required = true
)
String getPublicationDateProperty();
@Parameter(
name = "documentTypes",
required = true
)
String getDocumentTypes();
@Parameter(
name = "propertyCriteria",
defaultValue = ""
)
String getPropertyCriteria();
@Parameter(
name = "timezone",
defaultValue = "UTC"
)
String getTimezone();
@Parameter(
name = "publicationName",
defaultValue = ""
)
String getPublicationName();
@Parameter(
name = "publicationLanguage",
defaultValue = ""
)
String getPublicationLanguage();
@Parameter(
name = "newsInformationProvider",
defaultValue = ""
)
String getNewsInformationProviderClassname();
}
@Override
public void doBeforeRender(final HstRequest request, final HstResponse response) {
super.doBeforeRender(request, response);
NewsSitemapFeedParametersInformation parameters = getComponentParametersInfo(request);
verifyRequiredParametersAreFilled(parameters);
NewsInformationProvider newsInformationProvider = createNewsInformationProvider(parameters);
Map<String, String> propertyCriteria = parsePropertyCriteria(parameters.getPropertyCriteria());
String[] documentTypes = parameters.getDocumentTypes().trim().split("[\\s]*,[\\s]*");
HstQuery query = createQuery(
request,
documentTypes,
parameters.getTimezone(),
newsInformationProvider,
propertyCriteria
);
HstRequestContext requestContext = request.getRequestContext();
NewsSitemapGenerator sitemapGenerator =
new NewsSitemapGenerator(requestContext, newsInformationProvider, RequestContextProvider.get().getContentBeansTool().getObjectConverter());
NewsUrlset urlset = sitemapGenerator.createNewsSitemap(query);
String sitemap = NewsSitemapGenerator.toString(urlset);
request.setAttribute("sitemap", sitemap);
}
private HstQuery createQuery(final HstRequest request, final String[] documentTypes, final String timezone,
final NewsInformationProvider newsInformationProvider,
final Map<String, String> propertyCriteria) {
HippoBean siteContentBaseBean = request.getRequestContext().getSiteContentBaseBean();
HstQuery query;
try {
query = RequestContextProvider.get().getQueryManager().createQuery(siteContentBaseBean, documentTypes);
Filter filter = query.createFilter();
Calendar dateToObtainNewsSince = new GregorianCalendar(TimeZone.getTimeZone(timezone));
dateToObtainNewsSince.add(Calendar.HOUR_OF_DAY, -MAX_AGE_IN_HOURS);
filter.addGreaterThan(newsInformationProvider.getPublicationDateProperty(), dateToObtainNewsSince);
if (!propertyCriteria.isEmpty()) {
// Add property criteria
for (Map.Entry<String, String> propertyCriterion : propertyCriteria.entrySet()) {
filter.addEqualTo(propertyCriterion.getKey(), propertyCriterion.getValue());
}
}
query.setFilter(filter);
} catch (QueryException e) {
throw new HstComponentException("Cannot create HstQuery", e);
}
return query;
}
private static void verifyRequiredParametersAreFilled(final NewsSitemapFeedParametersInformation parameters){
if (StringUtils.isEmpty(parameters.getDocumentTypes())) {
throw new HstComponentException("No document types specified, please pass the parameter documentTypes");
}
if (StringUtils.isEmpty(parameters.getPublicationDateProperty())
&& StringUtils.isEmpty(parameters.getNewsInformationProviderClassname())
) {
throw new HstComponentException("No Publication date property specified, please pass the parameter " +
"publicationDateProperty");
}
}
private static NewsInformationProvider createNewsInformationProvider(
final NewsSitemapFeedParametersInformation parameters) {
boolean hasCustomProviderClass = StringUtils.isNotEmpty(parameters.getNewsInformationProviderClassname());
boolean hasPublicationInformation = StringUtils.isNotEmpty(parameters.getPublicationName()) &&
StringUtils.isNotEmpty(parameters.getPublicationLanguage());
if (!hasCustomProviderClass && !hasPublicationInformation) {
throw new HstComponentException("No publication information set and no custom NewsInformationProvider specified");
}
if (hasCustomProviderClass) {
return obtainInstanceForClass(NewsInformationProvider.class,
parameters.getNewsInformationProviderClassname());
} else {
return new DefaultNewsInformationProvider(
new Publication(parameters.getPublicationName(), parameters.getPublicationLanguage()),
parameters.getPublicationDateProperty()
);
}
}
/**
* Takes an input string with comma seperated property criteria (in the format prop1=condition1,prop2=condiion2...)
* and returns a map with key = property and value = criterion
*
* @param propertyCriteria comma seperated list of property criteria
* @return {@link Map} containing the property criteria
*/
private static Map<String, String> parsePropertyCriteria(final String propertyCriteria) {
if (StringUtils.isEmpty(propertyCriteria)) {
return Collections.emptyMap();
}
String[] criteria = propertyCriteria.trim().split("[\\s]*,[\\s]*");
Pattern propertyCriterionPattern = Pattern.compile("([\\w]+)[\\s]*=[\\s]*([\\w]+)");
Map<String, String> propertiesWithCriteria = new HashMap<String, String>();
for (final String criterion : criteria) {
Matcher propertyCriterionMatcher = propertyCriterionPattern.matcher(criterion);
if (!propertyCriterionMatcher.matches()) {
throw new HstComponentException("Criterion does not match pattern \"property=condition\"");
}
String property = propertyCriterionMatcher.group(1);
String condition = propertyCriterionMatcher.group(2);
propertiesWithCriteria.put(property, condition);
}
return propertiesWithCriteria;
}
}
/*
* Copyright 2010-2013 Hippo B.V. (http://www.onehippo.com)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.onehippo.forge.sitemap.components;
import org.hippoecm.hst.configuration.hosting.Mount;
import org.hippoecm.hst.content.beans.manager.ObjectConverter;
import org.hippoecm.hst.core.request.HstRequestContext;
import org.hippoecm.hst.jaxrs.services.AbstractResource;
import org.onehippo.forge.sitemap.components.model.Urlset;
import org.onehippo.forge.sitemap.components.splitter.SitemapSplitter;
import org.onehippo.forge.sitemap.components.splitter.TarGzipSitemapSplitter;
import org.onehippo.forge.sitemap.generator.DefaultUrlInformationProvider;
import org.onehippo.forge.sitemap.generator.SitemapGenerator;
import org.springframework.beans.factory.annotation.Required;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.ws.rs.GET;
import javax.ws.rs.Path;
import javax.ws.rs.Produces;
import javax.ws.rs.WebApplicationException;
import javax.ws.rs.core.Context;
import javax.ws.rs.core.MediaType;
import javax.ws.rs.core.Response;
import java.io.ByteArrayOutputStream;
import java.util.Collections;
import java.util.List;
/**
* This is a JAX-RS resource to be used in the Hippo REST-interface. It outputs a site map in different formats,
* including a tar.gz archive.
*/
@Path("sitemap")
public class SiteMapBasedOnHstSiteMapResource extends AbstractResource {
private List<String> exclusionsByRefId = Collections.emptyList();
private List<String> exclusionsByComponentConfigurationId = Collections.emptyList();
private List<String> exclusionsBySiteMapPath = Collections.emptyList();
private UrlInformationProvider urlInformationProvider = DefaultUrlInformationProvider.INSTANCE;
private int amountOfWorkers = -1;
private String mountAlias;
@GET
@Path("sitemap-archive.tar.gz")
@Produces({"application/zip", "application/x-gzip", "application/octet-stream", MediaType.APPLICATION_XML})
public Response createSiteMapTarGzArchive(@Context HttpServletRequest request,
@Context HttpServletResponse response) {
Urlset siteMap = obtainSiteMap(request);
final ByteArrayOutputStream siteMapArchiveStream = new ByteArrayOutputStream();
SitemapSplitter splitter = new TarGzipSitemapSplitter(siteMap, siteMapArchiveStream);
boolean splittingExecuted = splitter.split();
if (!splittingExecuted) {
throw new WebApplicationException(Response.Status.INTERNAL_SERVER_ERROR);
}
response.setHeader("Content-Disposition", "attachment; filename=sitemap-archive.tar.gz");
response.setContentType("application/x-gzip");
final Response.ResponseBuilder okResponse = Response.ok(siteMapArchiveStream.toByteArray(), MediaType.APPLICATION_OCTET_STREAM_TYPE);
return okResponse.build();
}
private Urlset obtainSiteMap(final HttpServletRequest request) {
HstRequestContext requestContext = getRequestContext(request);
ObjectConverter objectConverter = getObjectConverter(requestContext);
Mount mount = requestContext.getMount(mountAlias);
SitemapGenerator generator =
new SitemapGenerator(requestContext, objectConverter, urlInformationProvider, mount);
generator.addSitemapRefIdExclusions(exclusionsByRefId);
generator.addComponentConfigurationIdExclusions(exclusionsByComponentConfigurationId);
generator.addSitemapPathExclusions(exclusionsBySiteMapPath);
if (amountOfWorkers > 0) {
generator.setAmountOfWorkers(amountOfWorkers);
}
return generator.createUrlSetBasedOnHstSiteMap();
}
public void setExclusionsByRefId(final List<String> exclusionsByRefId) {
this.exclusionsByRefId = exclusionsByRefId != null ? exclusionsByRefId : Collections.<String>emptyList();
}
public void setExclusionsByComponentConfigurationId(final List<String> exclusionsByComponentConfigurationId) {
this.exclusionsByComponentConfigurationId = exclusionsByComponentConfigurationId != null ?
exclusionsByComponentConfigurationId : Collections.<String>emptyList();
}
public void setExclusionsBySiteMapPath(List<String> exclusionsBySiteMapPath) {
this.exclusionsBySiteMapPath = exclusionsBySiteMapPath != null ?
exclusionsBySiteMapPath : Collections.<String>emptyList();
}
public void setUrlInformationProvider(UrlInformationProvider urlInformationProvider) {
this.urlInformationProvider = urlInformationProvider;
}
public void setAmountOfWorkers(int amountOfWorkers) {
this.amountOfWorkers = amountOfWorkers;
}
@Required
public void setMountAlias(String mountAlias) {
this.mountAlias = mountAlias;
}
}
/*
* Copyright 2010-2013 Hippo B.V. (http://www.onehippo.com)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.onehippo.forge.sitemap.components;
import org.hippoecm.hst.component.support.bean.BaseHstComponent;
import org.hippoecm.hst.container.RequestContextProvider;
import org.hippoecm.hst.core.component.HstRequest;
import org.hippoecm.hst.core.component.HstResponse;
import org.hippoecm.hst.core.sitemenu.HstSiteMenus;
import org.onehippo.forge.sitemap.generator.SitemapGenerator;
public class SitemapFeed extends BaseHstComponent {
public static final int DEFAULT_DEPTH = 2;
public void doBeforeRender(HstRequest request, HstResponse response) {
String depthStr =getComponentParameter("depth");
int maxdepth = DEFAULT_DEPTH;
if (depthStr != null){
maxdepth = Integer.valueOf(depthStr);
}
HstSiteMenus siteMenus = request.getRequestContext().getHstSiteMenus();
request.setAttribute("sitemap", new SitemapGenerator(request.getRequestContext(), RequestContextProvider.get().getContentBeansTool().getObjectConverter())
.createSitemap(siteMenus, maxdepth));
}
}
/*
* Copyright 2012-2013 Hippo B.V. (http://www.onehippo.com)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.onehippo.forge.sitemap.components;
import static org.apache.commons.lang.StringUtils.isNotEmpty;
import org.apache.commons.lang.StringUtils;
import org.hippoecm.hst.component.support.bean.BaseHstComponent;
import org.hippoecm.hst.content.beans.standard.HippoBean;
import org.hippoecm.hst.core.component.HstComponentException;
import org.hippoecm.hst.core.component.HstRequest;
import org.hippoecm.hst.core.component.HstResponse;
import org.hippoecm.hst.core.parameters.Parameter;
import org.hippoecm.hst.core.parameters.ParametersInfo;
import org.onehippo.forge.sitemap.generator.SitemapIndexGenerator;
/**
* Serves a Sitemap IndexXML.
*
* @author Ricardo Sawirjo
*/
@SuppressWarnings({"unused" })
@ParametersInfo(type = SitemapIndexFeed.SitemapIndexFeedParametersInformation.class)
public class SitemapIndexFeed extends BaseHstComponent {
/**
* A sitemap index file will be created. This file will contain urls which points to the
* assets folder in the Hippo Repository.
* The sitemap-location-foldername must be configured via the console.
* Add a parameter at the following location: