public class SiteMap
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
private java.lang.String |
encoding |
private org.codehaus.plexus.i18n.I18N |
i18n |
| Constructor and Description |
|---|
SiteMap(java.lang.String encoding,
org.codehaus.plexus.i18n.I18N i18n)
Constructor sets default values.
|
| Modifier and Type | Method and Description |
|---|---|
private void |
extract(org.apache.maven.doxia.site.decoration.DecorationModel decoration,
org.apache.maven.doxia.sink.Sink sink,
java.util.Locale locale) |
private static void |
extractItems(java.util.List<org.apache.maven.doxia.site.decoration.MenuItem> items,
org.apache.maven.doxia.sink.Sink sink) |
void |
generate(org.apache.maven.doxia.site.decoration.DecorationModel model,
java.io.File targetDir,
java.util.Locale locale)
Generates a sitemap.xml in targetDir/xdoc/.
|
java.lang.String |
getEncoding()
Get the encoding to use when writing the output file.
|
org.codehaus.plexus.i18n.I18N |
getI18n()
Get the value of i18n.
|
private static java.lang.String |
relativePath(java.lang.String href) |
void |
setEncoding(java.lang.String enc)
Set the encoding to use when writing the output file.
|
void |
setI18n(org.codehaus.plexus.i18n.I18N i18n)
Set the value of i18n.
|
private java.lang.String encoding
private org.codehaus.plexus.i18n.I18N i18n
public SiteMap(java.lang.String encoding,
org.codehaus.plexus.i18n.I18N i18n)
encoding - the default encoding to use when writing the output file.i18n - the default I18N for translations.public org.codehaus.plexus.i18n.I18N getI18n()
public void setI18n(org.codehaus.plexus.i18n.I18N i18n)
i18n - new value of i18n.public java.lang.String getEncoding()
public void setEncoding(java.lang.String enc)
enc - new value of encoding.public void generate(org.apache.maven.doxia.site.decoration.DecorationModel model,
java.io.File targetDir,
java.util.Locale locale)
throws java.io.IOException
model - the DecorationModel to extract the menus from.targetDir - the target output directory. The file will be created in targetDir/xdoc/.locale - the Locale for the result.java.io.IOException - if the file cannot be ceated.private void extract(org.apache.maven.doxia.site.decoration.DecorationModel decoration,
org.apache.maven.doxia.sink.Sink sink,
java.util.Locale locale)
private static void extractItems(java.util.List<org.apache.maven.doxia.site.decoration.MenuItem> items,
org.apache.maven.doxia.sink.Sink sink)
private static java.lang.String relativePath(java.lang.String href)