## org.apache.maven.plugins.site
Class AbstractSiteRenderingMojo

    java.lang.Object
      org.apache.maven.plugin.AbstractMojo
          org.apache.maven.plugins.site.AbstractSiteMojo
              org.apache.maven.plugins.site.AbstractSiteRenderingMojo

All Implemented Interfaces:
  org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo

Direct Known Subclasses:
  SiteMojo, SiteRunMojo

    public abstract class AbstractSiteRenderingMojo

extends AbstractSiteMojo

Base class for site rendering mojos.

Version:
  $Id: AbstractSiteRenderingMojo.java 891014 2009-12-15 21:47:19Z ltheussl $
Author:
  Brett Porter

Field Summary
`protected org.apache.maven.artifact.factory.ArtifactFactory` `artifactFactory` The component used for creating artifact instances.
`protected org.apache.maven.artifact.resolver.ArtifactResolver` `artifactResolver` The component that is used to resolve additional artifacts required.
`protected org.apache.maven.doxia.site.decoration.inheritance.DecorationModelInheritanceAssembler` `assembler` The component for assembling inheritance.
`protected java.util.Map` `attributes` The template properties for rendering the site.
`protected java.io.File` `generatedSiteDirectory` Directory containing generated documentation.
`protected java.util.Map` `moduleExcludes` Module type exclusion mappings ex: `fml -> **/*-m1.fml` (excludes fml files ending in '-m1.fml' recursively) The configuration looks like this:
`protected java.util.List` `reports`
`protected java.util.List` `repositories` Remote repositories used for the project.
`protected org.apache.maven.doxia.siterenderer.Renderer` `siteRenderer` Site renderer.

Fields inherited from class org.apache.maven.plugins.site.AbstractSiteMojo
`i18n, locales, localRepository, project, reactorProjects, siteDirectory, siteTool`

Fields inherited from interface org.apache.maven.plugin.Mojo
`ROLE`

Constructor Summary
`AbstractSiteRenderingMojo()`

Method Summary
`protected java.util.Map` `categoriseReports(java.util.Collection reports)` Go through the collection of reports and put each report into a list for the appropriate category.
`protected org.apache.maven.doxia.siterenderer.SiteRenderingContext` `createSiteRenderingContext(java.util.Locale locale)`
`protected java.util.List` `filterReports(java.util.List reports)`
`protected java.util.Map` `locateDocuments(org.apache.maven.doxia.siterenderer.SiteRenderingContext context, java.util.List reports, java.util.Locale locale)`
`protected java.util.Map` `locateReports(java.util.List reports, java.util.Map documents, java.util.Locale locale)` Go through the list of reports and process each one like this: Add the report to a map of reports keyed by filename having the report itself as value If the report is not yet in the map of documents, add it together with a suitable renderer

Methods inherited from class org.apache.maven.plugins.site.AbstractSiteMojo
`getInputEncoding, getOutputEncoding, populateReportItems, toRelative`

Methods inherited from class org.apache.maven.plugin.AbstractMojo
`getLog, getPluginContext, setLog, setPluginContext`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Methods inherited from interface org.apache.maven.plugin.Mojo
`execute`

Field Detail

### moduleExcludes

    protected java.util.Map moduleExcludes

  Module type exclusion mappings ex: `fml -> **/*-m1.fml` (excludes fml files ending in '-m1.fml' recursively)

  The configuration looks like this:

         <moduleExcludes>
           <moduleType>filename1.ext,**/*sample.ext</moduleType>
           <!-- moduleType can be one of 'apt', 'fml' or 'xdoc'. -->
           <!-- The value is a comma separated list of           -->
           <!-- filenames or fileset patterns.                   -->
           <!-- Here's an example:                               -->
           <xdoc>changes.xml,navigation.xml</xdoc>
         </moduleExcludes>

### assembler

    protected org.apache.maven.doxia.site.decoration.inheritance.DecorationModelInheritanceAssembler assembler

  The component for assembling inheritance.

### artifactResolver

    protected org.apache.maven.artifact.resolver.ArtifactResolver artifactResolver

  The component that is used to resolve additional artifacts required.

### repositories

    protected java.util.List repositories

  Remote repositories used for the project.

### artifactFactory

    protected org.apache.maven.artifact.factory.ArtifactFactory artifactFactory

  The component used for creating artifact instances.

### attributes

    protected java.util.Map attributes

  The template properties for rendering the site.

### siteRenderer

    protected org.apache.maven.doxia.siterenderer.Renderer siteRenderer

  Site renderer.

### reports

    protected java.util.List reports

### generatedSiteDirectory

    protected java.io.File generatedSiteDirectory

  Directory containing generated documentation.

Constructor Detail

### AbstractSiteRenderingMojo

    public AbstractSiteRenderingMojo()

Method Detail

### filterReports

    protected java.util.List filterReports(java.util.List reports)

### createSiteRenderingContext

    protected org.apache.maven.doxia.siterenderer.SiteRenderingContext createSiteRenderingContext(java.util.Locale locale)
                                                                                           throws org.apache.maven.plugin.MojoExecutionException,
                                                                                                  java.io.IOException,
                                                                                                  org.apache.maven.plugin.MojoFailureException

  Throws:
    `org.apache.maven.plugin.MojoExecutionException`
    `java.io.IOException`
    `org.apache.maven.plugin.MojoFailureException`

### locateReports

    protected java.util.Map locateReports(java.util.List reports,
                                          java.util.Map documents,
                                          java.util.Locale locale)

  Go through the list of reports and process each one like this:
  - Add the report to a map of reports keyed by filename having the report itself as value
  - If the report is not yet in the map of documents, add it together with a suitable renderer

  Parameters:
    `reports` - A List of MavenReports
    `documents` - A Map of documents, keyed by filename
    `locale` - the Locale the reports are processed for.
  Returns:
    A map with all reports keyed by filename having the report itself as value. The map will be used to populate a menu.

### categoriseReports

    protected java.util.Map categoriseReports(java.util.Collection reports)

  Go through the collection of reports and put each report into a list for the appropriate category. The list is put into a map keyed by the name of the category.

  Parameters:
    `reports` - A Collection of MavenReports
  Returns:
    A map keyed category having the report itself as value

### locateDocuments

    protected java.util.Map locateDocuments(org.apache.maven.doxia.siterenderer.SiteRenderingContext context,
                                            java.util.List reports,
                                            java.util.Locale locale)
                                     throws java.io.IOException,
                                            org.apache.maven.doxia.siterenderer.RendererException

  Throws:
    `java.io.IOException`
    `org.apache.maven.doxia.siterenderer.RendererException`

Copyright © 2011. All Rights Reserved.