org.apache.maven.plugin.javadoc
Class TestJavadocReport

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.JavadocReport
              extended by org.apache.maven.plugin.javadoc.TestJavadocReport
All Implemented Interfaces:
ContextEnabled, Mojo, MavenReport
Direct Known Subclasses:
AggregatorTestJavadocReport, TestJavadocNoForkReport

@Mojo(name="test-javadoc",
      requiresDependencyResolution=TEST,
      threadSafe=true)
@Execute(phase=GENERATE_TEST_SOURCES)
public class TestJavadocReport
extends JavadocReport

Generates documentation for the Java Test code in an NON aggregator project using the standard Javadoc Tool.

Since:
2.3
Version:
$Id: TestJavadocReport.html 922314 2014-09-15 20:18:14Z dennisl $
Author:
Vincent Siveton
See Also:
Javadoc Tool, Javadoc Options

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, outputDirectory, PACKAGES_FILE_NAME, project, session, skip, TEST_JAVADOC_RESOURCES_ATTACHMENT_CLASSIFIER, useStandardDocletOptions
 
Fields inherited from interface org.apache.maven.reporting.MavenReport
CATEGORY_PROJECT_INFORMATION, CATEGORY_PROJECT_REPORTS, ROLE
 
Fields inherited from interface org.apache.maven.plugin.Mojo
ROLE
 
Constructor Summary
TestJavadocReport()
           
 
Method Summary
protected  SourceResolverConfig configureDependencySourceResolution(SourceResolverConfig config)
          Overridden to enable the resolution of -test-sources jar files.
protected  void executeReport(Locale unusedLocale)
          The package documentation details the Javadoc Options used by this Plugin.
protected  List<Artifact> getCompileArtifacts(ArtifactResolutionResult result)
           
 String getDescription(Locale locale)
          
protected  String getDoctitle()
           
protected  List<String> getExecutionProjectSourceRoots(MavenProject p)
           
protected  File getJavadocDirectory()
           
 String getName(Locale locale)
          
 String getOutputName()
          
protected  File getOverview()
           
protected  List<Artifact> getProjectArtifacts(MavenProject p)
           
protected  List<String> getProjectBuildOutputDirs(MavenProject p)
           
protected  List<String> getProjectSourceRoots(MavenProject p)
           
 File getReportOutputDirectory()
          
protected  String getWindowtitle()
           
 void setDestDir(String destDir)
           
 void setReportOutputDirectory(File reportOutputDirectory)
          Method to set the directory where the generated reports will be put
 
Methods inherited from class org.apache.maven.plugin.javadoc.JavadocReport
canGenerateReport, execute, generate, getCategoryName, isAggregator, isExternalReport
 
Methods inherited from class org.apache.maven.plugin.javadoc.AbstractJavadocMojo
buildJavadocOptions, canGenerateReport, failOnError, getAttachmentClassifier, getDependencySourcePaths, getFiles, getJavadocOptionsFile, getOutputDirectory, getProject, getSourcePaths, 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

TestJavadocReport

public TestJavadocReport()
Method Detail

executeReport

protected void executeReport(Locale unusedLocale)
                      throws MavenReportException
Description copied from class: AbstractJavadocMojo
The package documentation details the Javadoc Options used by this Plugin.

Overrides:
executeReport in class AbstractJavadocMojo
Parameters:
unusedLocale - the wanted locale (actually unused).
Throws:
MavenReportException - if any

getName

public String getName(Locale locale)
Description copied from class: JavadocReport

Specified by:
getName in interface MavenReport
Overrides:
getName in class JavadocReport

getDescription

public String getDescription(Locale locale)
Description copied from class: JavadocReport

Specified by:
getDescription in interface MavenReport
Overrides:
getDescription in class JavadocReport

getOutputName

public String getOutputName()
Description copied from class: JavadocReport

Specified by:
getOutputName in interface MavenReport
Overrides:
getOutputName in class JavadocReport

getReportOutputDirectory

public File getReportOutputDirectory()
Description copied from class: JavadocReport

Specified by:
getReportOutputDirectory in interface MavenReport
Overrides:
getReportOutputDirectory in class JavadocReport

setReportOutputDirectory

public void setReportOutputDirectory(File reportOutputDirectory)
Method to set the directory where the generated reports will be put

Specified by:
setReportOutputDirectory in interface MavenReport
Overrides:
setReportOutputDirectory in class JavadocReport
Parameters:
reportOutputDirectory - the directory file to be set

setDestDir

public void setDestDir(String destDir)
Overrides:
setDestDir in class JavadocReport

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

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

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)
Overridden 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–2014 The Apache Software Foundation. All rights reserved.