org.apache.maven.plugins.site
Class SiteStageMojo
java.lang.Object
org.apache.maven.plugin.AbstractMojo
org.apache.maven.plugins.site.AbstractSiteMojo
org.apache.maven.plugins.site.AbstractSiteRenderingMojo
org.apache.maven.plugins.site.SiteMojo
org.apache.maven.plugins.site.SiteStageMojo
- All Implemented Interfaces:
- org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo
- Direct Known Subclasses:
- SiteStageDeployMojo
public class SiteStageMojo
- extends SiteMojo
Generates a site in a local staging or mock directory based on the site URL
specified in the <distributionManagement> section of the
POM.
It can be used to test that links between module sites in a multi module
build works.
- Version:
- $Id: SiteStageMojo.java 751418 2009-03-08 13:27:17Z dennisl $
- Author:
- Vincent Siveton
| Fields inherited from interface org.apache.maven.plugin.Mojo |
ROLE |
|
Method Summary |
void |
execute()
Generate the project site
throws MojoExecutionException if any |
protected java.io.File |
getStagingDirectory(org.apache.maven.project.MavenProject currentProject,
java.util.List reactorProjects,
java.io.File usersStagingDirectory)
Find the directory where staging will take place. |
protected static java.lang.String |
getStructure(org.apache.maven.project.MavenProject project,
boolean ignoreMissingSiteUrl)
Generates the site structure using the project hiearchy (project and its modules) or using the
distributionManagement elements from the pom.xml. |
protected org.apache.maven.project.MavenProject |
getTopLevelProject(java.util.List reactorProjects)
Find the top level parent in the reactor, i.e. the execution root. |
| 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 |
DEFAULT_STAGING_DIRECTORY
protected static final java.lang.String DEFAULT_STAGING_DIRECTORY
- See Also:
- Constant Field Values
stagingDirectory
protected java.io.File stagingDirectory
- Staging directory location. This needs to be an absolute path, like
C:\stagingArea\myProject\ on Windows or
/stagingArea/myProject/ on Unix.
SiteStageMojo
public SiteStageMojo()
execute
public void execute()
throws org.apache.maven.plugin.MojoExecutionException,
org.apache.maven.plugin.MojoFailureException
- Description copied from class:
SiteMojo
- Generate the project site
throws MojoExecutionException if any
- Specified by:
execute in interface org.apache.maven.plugin.Mojo- Overrides:
execute in class SiteMojo
- Throws:
org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoFailureException- See Also:
Mojo.execute()
getStagingDirectory
protected java.io.File getStagingDirectory(org.apache.maven.project.MavenProject currentProject,
java.util.List reactorProjects,
java.io.File usersStagingDirectory)
- Find the directory where staging will take place.
- Parameters:
currentProject - The currently executing projectreactorProjects - The projects in the reactorusersStagingDirectory - The staging directory as suggested by the user's configuration
- Returns:
- the directory for staging
getTopLevelProject
protected org.apache.maven.project.MavenProject getTopLevelProject(java.util.List reactorProjects)
- Find the top level parent in the reactor, i.e. the execution root.
- Parameters:
reactorProjects - The projects in the reactor
- Returns:
- The top level project in the reactor, or
null if none can be found
getStructure
protected static java.lang.String getStructure(org.apache.maven.project.MavenProject project,
boolean ignoreMissingSiteUrl)
throws org.apache.maven.plugin.MojoFailureException
- Generates the site structure using the project hiearchy (project and its modules) or using the
distributionManagement elements from the pom.xml.
- Parameters:
project - ignoreMissingSiteUrl -
- Returns:
- the structure relative path
- Throws:
org.apache.maven.plugin.MojoFailureException - if any
Copyright © 2002-2009 The Apache Software Foundation. All Rights Reserved.