org.apache.maven.plugin.javadoc
Class TestJavadocJar

java.lang.Object
  extended by org.apache.maven.plugin.AbstractMojo
      extended by org.apache.maven.plugin.javadoc.AbstractJavadocMojo
          extended by org.apache.maven.plugin.javadoc.JavadocJar
              extended by org.apache.maven.plugin.javadoc.TestJavadocJar
All Implemented Interfaces:
ContextEnabled, Mojo
Direct Known Subclasses:
AggregatorTestJavadocJar

public class TestJavadocJar
extends JavadocJar

Bundles the Javadoc documentation for test Java code in an NON aggregator project into a jar using the standard Javadoc Tool.

Since:
2.5
Version:
$Id: TestJavadocJar.html 829400 2012-08-19 17:42:28Z hboutemy $
Author:
Vincent Siveton
Is defined by the goal name:
test-jar
Is bound to the specified phase of the standard build lifecycle:
package
Requires the dependencies in this specified scope:
test

Field Summary
 
Fields inherited from class org.apache.maven.plugin.javadoc.AbstractJavadocMojo
aggregate, ARGFILE_FILE_NAME, DEBUG_JAVADOC_SCRIPT_NAME, DEFAULT_JAVA_API_LINKS, failOnError, FILES_FILE_NAME, JAVADOC_RESOURCES_ATTACHMENT_CLASSIFIER, links, OPTIONS_FILE_NAME, PACKAGES_FILE_NAME, project, skip, TEST_JAVADOC_RESOURCES_ATTACHMENT_CLASSIFIER, useStandardDocletOptions
 
Fields inherited from interface org.apache.maven.plugin.Mojo
ROLE
 
Constructor Summary
TestJavadocJar()
           
 
Method Summary
protected  SourceResolverConfig configureDependencySourceResolution(SourceResolverConfig config)
          Overriden to enable the resolution of -test-sources jar files.
protected  String getClassifier()
           
protected  List<Artifact> getCompileArtifacts(ArtifactResolutionResult result)
           
protected  String getDoctitle()
           
protected  List<String> getExecutionProjectSourceRoots(MavenProject p)
           
protected  File getJavadocDirectory()
           
protected  String getOutputDirectory()
           
protected  File getOverview()
           
protected  List<Artifact> getProjectArtifacts(MavenProject p)
           
protected  List<String> getProjectBuildOutputDirs(MavenProject p)
           
protected  List<String> getProjectSourceRoots(MavenProject p)
           
protected  String getWindowtitle()
           
 
Methods inherited from class org.apache.maven.plugin.javadoc.JavadocJar
execute
 
Methods inherited from class org.apache.maven.plugin.javadoc.AbstractJavadocMojo
buildJavadocOptions, canGenerateReport, executeReport, failOnError, getAttachmentClassifier, getDependencySourcePaths, getFiles, getJavadocOptionsFile, getProject, getSourcePaths, isAggregator, logError, resolveDependency
 
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
 

Constructor Detail

TestJavadocJar

public TestJavadocJar()
Method Detail

getClassifier

protected String getClassifier()
Overrides:
getClassifier in class JavadocJar
Returns:
the wanted classifier, i.e. javadoc or test-javadoc

getOutputDirectory

protected String getOutputDirectory()
Overrides:
getOutputDirectory in class AbstractJavadocMojo
Returns:
the output directory

getJavadocDirectory

protected File getJavadocDirectory()
Overrides:
getJavadocDirectory in class AbstractJavadocMojo
Returns:
the current javadoc directory

getDoctitle

protected String getDoctitle()
Overrides:
getDoctitle in class AbstractJavadocMojo
Returns:
the title to be placed near the top of the overview summary file

getOverview

protected File getOverview()
Overrides:
getOverview in class AbstractJavadocMojo
Returns:
the overview documentation file from the user parameter or from the javadocdirectory

getWindowtitle

protected String getWindowtitle()
Overrides:
getWindowtitle in class AbstractJavadocMojo
Returns:
the title to be placed in the HTML title tag

getProjectBuildOutputDirs

protected List<String> getProjectBuildOutputDirs(MavenProject p)
Overrides:
getProjectBuildOutputDirs in class AbstractJavadocMojo
Parameters:
p - not null maven project
Returns:
the list of directories where compiled classes are placed for the given project. These dirs are added in the javadoc classpath.

getProjectSourceRoots

protected List<String> getProjectSourceRoots(MavenProject p)
Overrides:
getProjectSourceRoots in class AbstractJavadocMojo
Parameters:
p - not null maven project
Returns:
the list of source paths for the given project

getExecutionProjectSourceRoots

protected List<String> getExecutionProjectSourceRoots(MavenProject p)
Overrides:
getExecutionProjectSourceRoots in class AbstractJavadocMojo
Parameters:
p - not null maven project
Returns:
the list of source paths for the execution project of the given project

getProjectArtifacts

protected List<Artifact> getProjectArtifacts(MavenProject p)
Overrides:
getProjectArtifacts in class AbstractJavadocMojo
Parameters:
p - not null maven project
Returns:
the list of artifacts for the given project

getCompileArtifacts

protected List<Artifact> getCompileArtifacts(ArtifactResolutionResult result)
Overrides:
getCompileArtifacts in class AbstractJavadocMojo
Parameters:
result - not null
Returns:
the compile artifacts from the result
See Also:
JavadocUtil.getCompileArtifacts(Set, boolean)

configureDependencySourceResolution

protected SourceResolverConfig configureDependencySourceResolution(SourceResolverConfig config)
Overriden to enable the resolution of -test-sources jar files. Override this method to customize the configuration for resolving dependency sources. The default behavior enables the resolution of -sources jar files.

Overrides:
configureDependencySourceResolution in class AbstractJavadocMojo


Copyright © 2004-2012 The Apache Software Foundation. All Rights Reserved.