public abstract class AbstractFindbugsMojo
extends org.apache.maven.reporting.AbstractMavenReport
| Modifier and Type | Field and Description |
|---|---|
org.apache.maven.artifact.resolver.ArtifactResolver |
artifactResolver
Artifact resolver, needed to download the coreplugin jar.
|
File |
classFilesDirectory
Directory containing the class files for FindBugs to analyze.
|
List |
compileSourceRoots
The directories containing the sources to be compiled.
|
Boolean |
debug
turn on Findbugs debugging
|
String |
effort
Effort of the bug finders.
|
String |
excludeBugsFile
File names of the baseline files.
|
String |
excludeFilterFile
File name of the exclude filter.
|
org.apache.maven.artifact.factory.ArtifactFactory |
factory
Used to look up Artifacts in the remote repository.
|
boolean |
failOnError
Fail the build on an error.
|
boolean |
findbugsXmlOutput
Deprecated.
|
File |
findbugsXmlOutputDirectory
Specifies the directory where the findbugs native xml output will be generated.
|
boolean |
fork
Fork a VM for FindBugs analysis.
|
String |
includeFilterFile
File name of the include filter.
|
boolean |
includeTests
Run Findbugs on the tests.
|
String |
jvmArgs
the arguments to pass to the forked VM (ignored if fork is disabled).
|
org.apache.maven.artifact.repository.ArtifactRepository |
localRepository
The local repository, needed to download the coreplugin jar.
|
int |
maxHeap
Maximum Java heap size in megabytes (default=512).
|
int |
maxRank
Maximum bug ranking to record.
|
Boolean |
nested
This option enables or disables scanning of nested jar and zip files found
in the list of files and directories to be analyzed.
|
String |
omitVisitors
The visitor list to omit.
|
String |
onlyAnalyze
Restrict analysis to the given comma-separated list of classes and packages.
|
File |
outputDirectory
Location where generated html will be created.
|
String |
outputEncoding
The file encoding to use when creating the HTML reports.
|
ArrayList |
pluginArtifacts
List of artifacts this plugin depends on.
|
String |
pluginList
The plugin list to include in the report.
|
PluginArtifact[] |
plugins
Collection of PluginArtifact to work on.
|
org.apache.maven.project.MavenProject |
project
Maven Project
|
Boolean |
relaxed
Relaxed reporting mode.
|
List |
remoteArtifactRepositories
Remote repositories which will be searched for the coreplugin jar.
|
List |
remoteRepositories
List of Remote Repositories used by the resolver
|
org.codehaus.plexus.resource.ResourceManager |
resourceManager |
org.apache.maven.doxia.siterenderer.Renderer |
siteRenderer
Doxia Site Renderer.
|
org.apache.maven.doxia.tools.SiteTool |
siteTool
SiteTool.
|
boolean |
skip
Skip entire check.
|
String |
sourceEncoding
The file encoding to use when reading the source files.
|
File |
testClassFilesDirectory
Directory containing the test class files for FindBugs to analyze.
|
List |
testSourceRoots
The directories containing the test-sources to be compiled.
|
String |
threshold
Threshold of minimum bug severity to report.
|
int |
timeout
Specifies the amount of time, in milliseconds, that FindBugs may run before
it is assumed to be hung and is terminated.
|
Boolean |
trace
Prints a trace of detectors run and classes analyzed to standard output.
|
String |
visitors
The visitor list to run.
|
String |
xmlEncoding
Encoding used for xml files.
|
boolean |
xmlOutput
Turn on and off xml output of the Findbugs report.
|
File |
xmlOutputDirectory
Specifies the directory where the xml output will be generated.
|
File |
xrefLocation
Location of the Xrefs to link to.
|
File |
xrefTestLocation
Location of the Test Xrefs to link to.
|
| Constructor and Description |
|---|
AbstractFindbugsMojo() |
| Modifier and Type | Method and Description |
|---|---|
protected String |
getOutputDirectory()
Returns the report output directory.
|
protected org.apache.maven.project.MavenProject |
getProject()
Return the project.
|
canGenerateReport, closeReport, execute, executeReport, generate, generate, generate, getCategoryName, getReportOutputDirectory, getSink, getSinkFactory, getSiteRenderer, isExternalReport, setReportOutputDirectorygetLog, getPluginContext, setLog, setPluginContext@Parameter(defaultValue="${project.reporting.outputDirectory}",
required=true)
public File outputDirectory
@Parameter(defaultValue="false",
property="findbugs.xmlOutput",
required=true)
public boolean xmlOutput
@Parameter(defaultValue="${project.build.directory}",
required=true)
public File xmlOutputDirectory
@Deprecated @Parameter(defaultValue="true") public boolean findbugsXmlOutput
@Parameter(defaultValue="${project.build.directory}",
required=true)
public File findbugsXmlOutputDirectory
@Component(role=org.apache.maven.doxia.siterenderer.Renderer.class) public org.apache.maven.doxia.siterenderer.Renderer siteRenderer
@Parameter(defaultValue="${project.build.outputDirectory}",
required=true)
public File classFilesDirectory
@Parameter(defaultValue="${project.build.testOutputDirectory}",
required=true)
public File testClassFilesDirectory
@Parameter(defaultValue="${project.reporting.outputDirectory}/xref")
public File xrefLocation
@Parameter(defaultValue="${project.reporting.outputDirectory}/xref-test")
public File xrefTestLocation
@Parameter(defaultValue="${project.compileSourceRoots}",
required=true,
readonly=true)
public List compileSourceRoots
@Parameter(defaultValue="${project.testCompileSourceRoots}",
required=true,
readonly=true)
public List testSourceRoots
@Parameter(defaultValue="false",
property="findbugs.includeTests")
public boolean includeTests
@Parameter(property="plugin.artifacts",
required=true,
readonly=true)
public ArrayList pluginArtifacts
@Parameter(property="project.remoteArtifactRepositories",
required=true,
readonly=true)
public List remoteRepositories
@Parameter(property="localRepository",
required=true,
readonly=true)
public org.apache.maven.artifact.repository.ArtifactRepository localRepository
@Parameter(property="project.remoteArtifactRepositories",
required=true,
readonly=true)
public List remoteArtifactRepositories
@Parameter(property="project",
required=true,
readonly=true)
public org.apache.maven.project.MavenProject project
@Parameter(defaultValue="UTF-8",
readonly=true)
public String xmlEncoding
@Parameter(defaultValue="${project.build.sourceEncoding}",
property="encoding")
public String sourceEncoding
project.build.sourceEncoding
is not set, the platform default encoding is used.@Parameter(defaultValue="${project.reporting.outputEncoding}",
property="outputEncoding")
public String outputEncoding
project.reporting.outputEncoding
is not set, the platform default encoding is used.@Parameter(defaultValue="Default",
property="findbugs.threshold")
public String threshold
@Component(role=org.apache.maven.artifact.resolver.ArtifactResolver.class) public org.apache.maven.artifact.resolver.ArtifactResolver artifactResolver
@Parameter(property="component.org.apache.maven.artifact.factory.ArtifactFactory",
required=true,
readonly=true)
public org.apache.maven.artifact.factory.ArtifactFactory factory
@Parameter(property="findbugs.includeFilterFile") public String includeFilterFile
File name of the include filter. Only bugs in matching the filters are reported.
Potential values are a filesystem path, a URL, or a classpath resource.
This parameter is resolved as resource, URL, then file. If successfully
resolved, the contents of the configuration is copied into the
${project.build.directory}
directory before being passed to Findbugs as a filter file.
@Parameter(property="findbugs.excludeFilterFile") public String excludeFilterFile
File name of the exclude filter. Bugs matching the filters are not reported.
Potential values are a filesystem path, a URL, or a classpath resource.
This parameter is resolved as resource, URL, then file. If successfully
resolved, the contents of the configuration is copied into the
${project.build.directory}
directory before being passed to Findbugs as a filter file.
@Parameter(property="findbugs.excludeBugsFile") public String excludeBugsFile
File names of the baseline files. Bugs found in the baseline files won't be reported.
Potential values are a filesystem path, a URL, or a classpath resource.
This parameter is resolved as resource, URL, then file. If successfully
resolved, the contents of the configuration is copied into the
${project.build.directory}
directory before being passed to Findbugs as a filter file.
@Parameter(defaultValue="Default",
property="findbugs.effort")
public String effort
@Parameter(defaultValue="false",
property="findbugs.debug")
public Boolean debug
@Parameter(defaultValue="false",
property="findbugs.relaxed")
public Boolean relaxed
@Parameter(property="findbugs.visitors") public String visitors
@Parameter(property="findbugs.omitVisitors") public String omitVisitors
@Parameter(property="findbugs.pluginList") public String pluginList
The plugin list to include in the report. This is a comma-delimited list.
Potential values are a filesystem path, a URL, or a classpath resource.
This parameter is resolved as resource, URL, then file. If successfully
resolved, the contents of the configuration is copied into the
${project.build.directory}
directory before being passed to Findbugs as a plugin file.
@Parameter public PluginArtifact[] plugins
Collection of PluginArtifact to work on. (PluginArtifact contains groupId, artifactId, version, type.) See Usage for details.
@Parameter(property="findbugs.onlyAnalyze") public String onlyAnalyze
@Parameter(property="findbugs.nested",
defaultValue="false")
public Boolean nested
@Parameter(property="findbugs.trace",
defaultValue="false")
public Boolean trace
@Parameter(property="findbugs.maxRank") public int maxRank
@Parameter(property="findbugs.skip",
defaultValue="false")
public boolean skip
@Component(role=org.codehaus.plexus.resource.ResourceManager.class) public org.codehaus.plexus.resource.ResourceManager resourceManager
@Component(role=org.apache.maven.doxia.tools.SiteTool.class) public org.apache.maven.doxia.tools.SiteTool siteTool
@Parameter(property="findbugs.failOnError",
defaultValue="true")
public boolean failOnError
@Parameter(property="findbugs.fork",
defaultValue="true")
public boolean fork
@Parameter(property="findbugs.maxHeap",
defaultValue="512")
public int maxHeap
@Parameter(property="findbugs.timeout",
defaultValue="600000")
public int timeout
@Parameter(property="findbugs.jvmArgs") public String jvmArgs
the arguments to pass to the forked VM (ignored if fork is disabled).
protected org.apache.maven.project.MavenProject getProject()
getProject in class org.apache.maven.reporting.AbstractMavenReportAbstractMavenReport.getProject()protected String getOutputDirectory()
getOutputDirectory in class org.apache.maven.reporting.AbstractMavenReportAbstractMavenReport.getOutputDirectory()Copyright © 2005–2015 Codehaus. All rights reserved.