|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.maven.plugin.AbstractMojo
org.apache.maven.plugin.javadoc.AbstractJavadocMojo
public abstract class AbstractJavadocMojo
Base class with majority of Javadoc functionalities.
| Field Summary | |
|---|---|
protected boolean |
aggregate
Deprecated. since 2.5. Use the goals javadoc:aggregate and javadoc:test-aggregate instead. |
protected static String |
ARGFILE_FILE_NAME
The argfile file name in the output directory when calling:
javadoc.exe(or .sh) @options @packages | @argfile | @files |
protected static String |
DEBUG_JAVADOC_SCRIPT_NAME
The Javadoc script file name when debug parameter is on, i.e. |
static Properties |
DEFAULT_JAVA_API_LINKS
The default Javadoc API urls according the Sun API Specifications: |
protected boolean |
failOnError
Specifies if the build will fail if there are errors during javadoc execution or not. |
protected static String |
FILES_FILE_NAME
The files file name in the output directory when calling:
javadoc.exe(or .sh) @options @packages | @argfile | @files |
static String |
JAVADOC_RESOURCES_ATTACHMENT_CLASSIFIER
Classifier used in the name of the javadoc-options XML file, and in the resources bundle artifact that gets attached to the project. |
protected ArrayList<String> |
links
Creates links to existing javadoc-generated documentation of external referenced classes. |
protected static String |
OPTIONS_FILE_NAME
The options file name in the output directory when calling:
javadoc.exe(or .sh) @options @packages | @argfile | @files |
protected File |
outputDirectory
Specifies the destination directory where javadoc saves the generated HTML files. |
protected static String |
PACKAGES_FILE_NAME
The packages file name in the output directory when calling:
javadoc.exe(or .sh) @options @packages | @argfile | @files |
protected MavenProject |
project
The Maven Project Object |
protected boolean |
skip
Specifies whether the Javadoc generation should be skipped. |
static String |
TEST_JAVADOC_RESOURCES_ATTACHMENT_CLASSIFIER
Classifier used in the name of the javadoc-options XML file, and in the resources bundle artifact that gets attached to the project. |
protected boolean |
useStandardDocletOptions
Specifies to use the options provided by the Standard Doclet for a custom doclet. |
| Fields inherited from interface org.apache.maven.plugin.Mojo |
|---|
ROLE |
| Constructor Summary | |
|---|---|
AbstractJavadocMojo()
|
|
| Method Summary | |
|---|---|
protected JavadocOptions |
buildJavadocOptions()
Generate a javadoc-options XML file, for either bundling with a javadoc-resources artifact OR supplying to a distro module in a includeDependencySources configuration, so the javadoc options from this execution can be reconstructed and merged in the distro build. |
protected boolean |
canGenerateReport(List<String> files)
Method that indicates whether the javadoc can be generated or not. |
protected SourceResolverConfig |
configureDependencySourceResolution(SourceResolverConfig config)
Override this method to customize the configuration for resolving dependency sources. |
protected void |
executeReport(Locale unusedLocale)
The package documentation details the Javadoc Options used by this Plugin. |
protected void |
failOnError(String prefix,
Exception e)
|
protected String |
getAttachmentClassifier()
Override this if you need to provide a bundle attachment classifier, as in the case of test javadocs. |
protected List<Artifact> |
getCompileArtifacts(ArtifactResolutionResult result)
|
protected List<String> |
getDependencySourcePaths()
Resolve dependency sources so they can be included directly in the javadoc process. |
protected String |
getDoctitle()
|
protected List<String> |
getExecutionProjectSourceRoots(MavenProject p)
|
protected List<String> |
getFiles(List<String> sourcePaths)
Method to get the files on the specified source paths |
protected File |
getJavadocDirectory()
|
protected File |
getJavadocOptionsFile()
Construct the output file for the generated javadoc-options XML file, after creating the javadocOptionsDir if necessary. |
protected String |
getOutputDirectory()
|
protected File |
getOverview()
|
protected MavenProject |
getProject()
|
protected List<Artifact> |
getProjectArtifacts(MavenProject p)
|
protected List<String> |
getProjectBuildOutputDirs(MavenProject p)
|
protected List<String> |
getProjectSourceRoots(MavenProject p)
|
protected List<String> |
getSourcePaths()
Method to get the source paths. |
protected String |
getWindowtitle()
|
protected boolean |
isAggregator()
Indicates whether this goal is flagged with @aggregator. |
protected void |
logError(String message,
Throwable t)
Logs an error with throwable content only if in debug. |
Artifact |
resolveDependency(Dependency dependency)
|
| 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 |
|---|
public static final String JAVADOC_RESOURCES_ATTACHMENT_CLASSIFIER
TEST_JAVADOC_RESOURCES_ATTACHMENT_CLASSIFIER,
Constant Field Valuespublic static final String TEST_JAVADOC_RESOURCES_ATTACHMENT_CLASSIFIER
JAVADOC_RESOURCES_ATTACHMENT_CLASSIFIER,
Constant Field Valuespublic static final Properties DEFAULT_JAVA_API_LINKS
<javaApiLinks>
<property>
<name>api_1.3</name>
<value>http://download.oracle.com/javase/1.3/docs/api/</value>
</property>
<property>
<name>api_1.4</name>
<value>http://download.oracle.com/javase/1.4.2/docs/api/</value>
</property>
<property>
<name>api_1.5</name>
<value>http://download.oracle.com/javase/1.5.0/docs/api/</value>
</property>
<property>
<name>api_1.6</name>
<value>http://download.oracle.com/javase/6/docs/api/</value>
</property>
<property>
<name>api_1.7</name>
<value>http://download.oracle.com/javase/7/docs/api/</value>
</property>
</javaApiLinks>
protected static final String DEBUG_JAVADOC_SCRIPT_NAME
debug parameter is on, i.e. javadoc.bat or javadoc.sh
protected static final String OPTIONS_FILE_NAME
options file name in the output directory when calling:
javadoc.exe(or .sh) @options @packages | @argfile | @files
protected static final String PACKAGES_FILE_NAME
packages file name in the output directory when calling:
javadoc.exe(or .sh) @options @packages | @argfile | @files
protected static final String ARGFILE_FILE_NAME
argfile file name in the output directory when calling:
javadoc.exe(or .sh) @options @packages | @argfile | @files
protected static final String FILES_FILE_NAME
files file name in the output directory when calling:
javadoc.exe(or .sh) @options @packages | @argfile | @files
protected MavenProject project
protected boolean aggregate
javadoc:aggregate and javadoc:test-aggregate instead.
protected boolean skip
protected boolean failOnError
protected boolean useStandardDocletOptions
<docletArtifacts> <docletArtifact> <groupId>com.sun.tools.doclets</groupId> <artifactId>doccheck</artifactId> <version>1.2b2</version> </docletArtifact> </docletArtifacts> <useStandardDocletOptions>true</useStandardDocletOptions>
protected ArrayList<String> links
isOffline is set to false./package-list file. For instance:
<links> <link>http://download.oracle.com/javase/1.4.2/docs/api</link> <links>will be used because
http://download.oracle.com/javase/1.4.2/docs/api/package-list exists.detectLinks is defined, the links between the project dependencies are
automatically added.detectJavaApiLink is defined, a Java API link, based on the Java version of the
project's sources, will be added automatically.
detectLinks,
detectJavaApiLinkprotected File outputDirectory
| Constructor Detail |
|---|
public AbstractJavadocMojo()
| Method Detail |
|---|
protected boolean isAggregator()
@aggregator.
true if the goal is designed as an aggregator, false otherwise.AggregatorJavadocReport,
AggregatorTestJavadocReportprotected String getOutputDirectory()
protected MavenProject getProject()
protected List<String> getProjectBuildOutputDirs(MavenProject p)
p - not null maven project
protected List<String> getProjectSourceRoots(MavenProject p)
p - not null maven project
protected List<String> getExecutionProjectSourceRoots(MavenProject p)
p - not null maven project
protected List<Artifact> getProjectArtifacts(MavenProject p)
p - not null maven project
protected File getJavadocDirectory()
protected String getDoctitle()
protected File getOverview()
javadocdirectoryprotected String getWindowtitle()
protected void executeReport(Locale unusedLocale)
throws MavenReportException
unusedLocale - the wanted locale (actually unused).
MavenReportException - if any
protected List<String> getFiles(List<String> sourcePaths)
throws MavenReportException
sourcePaths - a List that contains the paths to the source files
MavenReportException
protected List<String> getSourcePaths()
throws MavenReportException
String
MavenReportExceptionJavadocUtil.pruneDirs(MavenProject, List)protected SourceResolverConfig configureDependencySourceResolution(SourceResolverConfig config)
protected final List<String> getDependencySourcePaths()
throws MavenReportException
configureDependencySourceResolution(SourceResolverConfig).
MavenReportExceptionprotected boolean canGenerateReport(List<String> files)
files - the project files
protected List<Artifact> getCompileArtifacts(ArtifactResolutionResult result)
result - not null
JavadocUtil.getCompileArtifacts(Set, boolean)
public Artifact resolveDependency(Dependency dependency)
throws MavenReportException
MavenReportExceptionprotected final File getJavadocOptionsFile()
protected final JavadocOptions buildJavadocOptions()
throws IOException
IOExceptionprotected String getAttachmentClassifier()
protected void logError(String message,
Throwable t)
message - t -
protected void failOnError(String prefix,
Exception e)
throws MojoExecutionException
MojoExecutionException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||