Package scala_maven
Class ScalaDocMojo
java.lang.Object
org.apache.maven.plugin.AbstractMojo
scala_maven.ScalaMojoSupport
scala_maven.ScalaSourceMojoSupport
scala_maven.ScalaDocMojo
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled
,org.apache.maven.plugin.Mojo
,org.apache.maven.reporting.MavenReport
- Direct Known Subclasses:
ScalaDocJarMojo
@Mojo(name="doc",
requiresDependencyResolution=COMPILE)
@Execute(phase=GENERATE_RESOURCES)
public class ScalaDocMojo
extends ScalaSourceMojoSupport
implements org.apache.maven.reporting.MavenReport
Produces Scala API documentation.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected boolean
If you want to aggregate only direct sub modules.protected String
Specifies the text to be placed at the bottom of each output file.protected String
Charset for cross-platform viewing of generated documentation.private String
The description of the Scaladoc report.protected String
Include title for the overview page.protected String
Include footer text for each page.protected boolean
To allow running aggregation only from command line use "-DforceAggregate=true" (avoid using in pom.xml).protected String
Include header text for each page [scaladoc, vscaladoc]protected boolean
Generate source in HTML [scaladoc, vscaladoc]private String
The name of the Scaladoc report.protected boolean
Suppress description and tags, generate only declarations [scaladoc, vscaladoc]protected String
Specifies the destination directory where scalaDoc saves the generated HTML files.protected File
Specifies the destination directory where javadoc saves the generated HTML files.protected String
className (FQN) of the main scaladoc to use, if not define, the the scalaClassName is usedprotected File
The directory which contains scala/java source filesprotected File
File to change style of the generated documentation [scaladoc, vscaladoc]protected String
Include top text for each page [scaladoc, vscaladoc]protected String
If you want to use vscaladoc to generate api instead of regular scaladoc, set the version of vscaladoc you want to use.protected String
Specify window title of generated HTML documentation.Fields inherited from class scala_maven.ScalaSourceMojoSupport
excludes, includes, sendJavaToScalac
Fields inherited from class scala_maven.ScalaMojoSupport
addJavacArgs, addScalacArgs, args, checkMultipleScalaVersions, compilerPlugins, dependencies, displayCmd, encoding, factory, failOnMultipleScalaVersions, forceUseArgFile, fork, JAR, javacArgs, javacGenerateDebugSymbols, jvmArgs, localRepo, mavenProjectBuilder, POM, project, reactorProjects, remoteRepos, resolver, SCALA_COMPILER_ARTIFACTID, SCALA_LIBRARY_ARTIFACTID, scalaClassName, session, source, target, toolchainManager, useCanonicalPath
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
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected void
aggregate
(org.apache.maven.project.MavenProject parent) private boolean
boolean
void
void
void
private String
Method that sets the bottom text that will be displayed on the bottom of the javadocs.getDescription
(Locale locale) protected JavaMainCaller
Retrieves the list of *all* root source directories.boolean
void
protected void
tryAggregateUpper
(org.apache.maven.project.MavenProject prj) Methods inherited from class scala_maven.ScalaSourceMojoSupport
findSourceWithFilters, findSourceWithFilters, initFilters, normalize
Methods inherited from class scala_maven.ScalaMojoSupport
addCompilerPluginOptions, addCompilerToClasspath, addLibraryToClasspath, addToClasspath, addToClasspath, addToClasspath, addToClasspath, checkScalaVersion, execute, findScalaVersion, findVersionFromDependencies, findVersionFromPluginArtifacts, getAllDependencies, getArtifactJar, getArtifactJar, getCompilerDependencies, getCompilerJar, getCompilerPluginOptions, getDependencies, getEmptyScalaCommand, getEmptyScalaCommand, getJavacOptions, getLibraryJar, getPluginArtifactJar, getPluginArtifactJar, getScalaCommand, getScalaOptions, getScalaOrganization, isJavaSupportedByCompiler, resolveArtifactDependencies, resolveDependencyArtifacts, resolveDependencyArtifacts, scalaCompilerArtifact
Methods inherited from class org.apache.maven.plugin.AbstractMojo
getLog, getPluginContext, setLog, setPluginContext
-
Field Details
-
windowtitle
@Parameter(property="windowtitle", defaultValue="${project.name} ${project.version} API") protected String windowtitleSpecify window title of generated HTML documentation. [scaladoc, vscaladoc] -
bottom
@Parameter(property="bottom", defaultValue="Copyright (c) {inceptionYear}-{currentYear} {organizationName}. All Rights Reserved.") protected String bottomSpecifies the text to be placed at the bottom of each output file. If you want to use html you have to put it in a CDATA section, eg. <![CDATA[Copyright 2005, <a href="http://www.mycompany.com">MyCompany, Inc.<a>]]> [scaladoc, vscaladoc] -
charset
Charset for cross-platform viewing of generated documentation. [scaladoc, vscaladoc] -
doctitle
@Parameter(property="doctitle", defaultValue="${project.name} ${project.version} API") protected String doctitleInclude title for the overview page. [scaladoc, scaladoc2, vscaladoc] -
header
Include header text for each page [scaladoc, vscaladoc] -
linksource
@Parameter(property="linksource", defaultValue="true") protected boolean linksourceGenerate source in HTML [scaladoc, vscaladoc] -
nocomment
@Parameter(property="nocomment", defaultValue="false") protected boolean nocommentSuppress description and tags, generate only declarations [scaladoc, vscaladoc] -
stylesheetfile
File to change style of the generated documentation [scaladoc, vscaladoc] -
top
Include top text for each page [scaladoc, vscaladoc] -
outputDirectory
Specifies the destination directory where scalaDoc saves the generated HTML files. -
reportOutputDirectory
@Parameter(defaultValue="${project.reporting.outputDirectory}/scaladocs", required=true) protected File reportOutputDirectorySpecifies the destination directory where javadoc saves the generated HTML files. -
name
The name of the Scaladoc report.- Since:
- 2.1
-
description
@Parameter(property="description", defaultValue="ScalaDoc API documentation.") private String descriptionThe description of the Scaladoc report.- Since:
- 2.1
-
scaladocClassName
className (FQN) of the main scaladoc to use, if not define, the the scalaClassName is used -
vscaladocVersion
If you want to use vscaladoc to generate api instead of regular scaladoc, set the version of vscaladoc you want to use. -
forceAggregate
@Parameter(property="forceAggregate", defaultValue="false") protected boolean forceAggregateTo allow running aggregation only from command line use "-DforceAggregate=true" (avoid using in pom.xml). [scaladoc, vscaladoc] -
aggregateDirectOnly
@Parameter(property="maven.scaladoc.aggregateDirectOnly", defaultValue="true") protected boolean aggregateDirectOnlyIf you want to aggregate only direct sub modules. -
sourceDir
The directory which contains scala/java source files -
_sourceFiles
-
-
Constructor Details
-
ScalaDocMojo
public ScalaDocMojo()
-
-
Method Details
-
getSourceDirectories
Description copied from class:ScalaSourceMojoSupport
Retrieves the list of *all* root source directories. We need to pass all .java and .scala files into the scala compiler- Specified by:
getSourceDirectories
in classScalaSourceMojoSupport
- Throws:
Exception
-
canGenerateReport
public boolean canGenerateReport()- Specified by:
canGenerateReport
in interfaceorg.apache.maven.reporting.MavenReport
-
findSourceFiles
- Returns:
- Throws:
Exception
-
canAggregate
private boolean canAggregate() -
isExternalReport
public boolean isExternalReport()- Specified by:
isExternalReport
in interfaceorg.apache.maven.reporting.MavenReport
-
getCategoryName
- Specified by:
getCategoryName
in interfaceorg.apache.maven.reporting.MavenReport
-
getDescription
- Specified by:
getDescription
in interfaceorg.apache.maven.reporting.MavenReport
-
getName
- Specified by:
getName
in interfaceorg.apache.maven.reporting.MavenReport
-
getOutputName
- Specified by:
getOutputName
in interfaceorg.apache.maven.reporting.MavenReport
-
getReportOutputDirectory
- Specified by:
getReportOutputDirectory
in interfaceorg.apache.maven.reporting.MavenReport
-
setReportOutputDirectory
- Specified by:
setReportOutputDirectory
in interfaceorg.apache.maven.reporting.MavenReport
-
doExecute
- Specified by:
doExecute
in classScalaMojoSupport
- Throws:
Exception
-
getScalaCommand
- Overrides:
getScalaCommand
in classScalaMojoSupport
- Throws:
Exception
-
generate
public void generate(org.apache.maven.doxia.sink.Sink sink, Locale locale) throws org.apache.maven.reporting.MavenReportException - Specified by:
generate
in interfaceorg.apache.maven.reporting.MavenReport
- Throws:
org.apache.maven.reporting.MavenReportException
-
generate
public void generate(org.codehaus.doxia.sink.Sink sink, Locale locale) throws org.apache.maven.reporting.MavenReportException - Throws:
org.apache.maven.reporting.MavenReportException
-
tryAggregateUpper
- Throws:
Exception
-
aggregate
- Throws:
Exception
-
getBottomText
Method that sets the bottom text that will be displayed on the bottom of the javadocs.- Returns:
- a String that contains the text that will be displayed at the bottom of the javadoc
-