Comparable<Task>
, org.gradle.api.internal.DynamicObjectAware
, org.gradle.api.internal.IConventionAware
, org.gradle.api.internal.TaskInternal
, ExtensionAware
, Reporting<FindBugsReports>
, Task
, PatternFilterable
, VerificationTask
, org.gradle.util.Configurable<Task>
@Deprecated @CacheableTask public class FindBugs extends SourceTask implements VerificationTask, Reporting<FindBugsReports>
Task.Namer
TASK_ACTION, TASK_CONSTRUCTOR_ARGS, TASK_DEPENDS_ON, TASK_DESCRIPTION, TASK_GROUP, TASK_NAME, TASK_OVERWRITE, TASK_TYPE
Constructor | Description |
---|---|
FindBugs() |
Deprecated.
|
Modifier and Type | Method | Description |
---|---|---|
FindBugs |
extraArgs(Iterable<String> arguments) |
Deprecated.
Any additional arguments (not covered here more explicitly like
effort ) to be passed along to FindBugs. |
FindBugs |
extraArgs(String... arguments) |
Deprecated.
Any additional arguments (not covered here more explicitly like
effort ) to be passed along to FindBugs. |
protected FileCollection |
getCandidateClassFiles() |
Deprecated.
The classes to be analyzed.
|
FileCollection |
getClasses() |
Deprecated.
The class directories to be analyzed.
|
FileCollection |
getClasspath() |
Deprecated.
Compile class path for the classes to be analyzed.
|
String |
getEffort() |
Deprecated.
The analysis effort level.
|
File |
getExcludeBugsFilter() |
Deprecated.
The filename of a filter specifying baseline bugs to exclude from being reported.
|
TextResource |
getExcludeBugsFilterConfig() |
Deprecated.
A filter specifying baseline bugs to exclude from being reported.
|
File |
getExcludeFilter() |
Deprecated.
The filename of a filter specifying bugs to exclude from being reported.
|
TextResource |
getExcludeFilterConfig() |
Deprecated.
A filter specifying bugs to exclude from being reported.
|
Collection<String> |
getExtraArgs() |
Deprecated.
Any additional arguments (not covered here more explicitly like
effort ) to be passed along to FindBugs. |
FileCollection |
getFindbugsClasspath() |
Deprecated.
Class path holding the FindBugs library.
|
boolean |
getIgnoreFailures() |
Deprecated.
Whether to allow the build to continue if there are warnings.
|
File |
getIncludeFilter() |
Deprecated.
The filename of a filter specifying which bugs are reported.
|
TextResource |
getIncludeFilterConfig() |
Deprecated.
A filter specifying which bugs are reported.
|
Collection<String> |
getJvmArgs() |
Deprecated.
Any additional arguments to be passed along to FindBugs JVM process.
|
String |
getMaxHeapSize() |
Deprecated.
The maximum heap size for the forked findbugs process (ex: '1g').
|
protected ObjectFactory |
getObjectFactory() |
Deprecated.
|
Collection<String> |
getOmitVisitors() |
Deprecated.
Similar to
visitors except that it specifies bug detectors which should not be run. |
FileCollection |
getPluginClasspath() |
Deprecated.
Class path holding any additional FindBugs plugins.
|
String |
getReportLevel() |
Deprecated.
The priority threshold for reporting bugs.
|
FindBugsReports |
getReports() |
Deprecated.
The reports to be generated by this task.
|
boolean |
getShowProgress() |
Deprecated.
Indicates whether analysis progress should be rendered on standard output.
|
FileTree |
getSource() |
Deprecated.
Returns the source for this task, after the include and exclude patterns have been applied.
|
Collection<String> |
getVisitors() |
Deprecated.
The bug detectors which should be run.
|
org.gradle.process.internal.worker.WorkerProcessFactory |
getWorkerProcessBuilderFactory() |
Deprecated.
|
FindBugs |
jvmArgs(Iterable<String> arguments) |
Deprecated.
Any additional arguments to be passed along to FindBugs JVM process.
|
FindBugs |
jvmArgs(String... arguments) |
Deprecated.
Any additional arguments to be passed along to FindBugs JVM process.
|
FindBugsReports |
reports(Closure closure) |
Deprecated.
Configures the reports to be generated by this task.
|
FindBugsReports |
reports(Action<? super FindBugsReports> configureAction) |
Deprecated.
Configures the reports to be generated by this task.
|
void |
run() |
Deprecated.
|
void |
setClasses(FileCollection classes) |
Deprecated.
The class directories to be analyzed.
|
void |
setClasspath(FileCollection classpath) |
Deprecated.
Compile class path for the classes to be analyzed.
|
void |
setEffort(String effort) |
Deprecated.
The analysis effort level.
|
void |
setExcludeBugsFilter(File filter) |
Deprecated.
The filename of a filter specifying baseline bugs to exclude from being reported.
|
void |
setExcludeBugsFilterConfig(TextResource excludeBugsFilterConfig) |
Deprecated.
A filter specifying baseline bugs to exclude from being reported.
|
void |
setExcludeFilter(File filter) |
Deprecated.
The filename of a filter specifying bugs to exclude from being reported.
|
void |
setExcludeFilterConfig(TextResource excludeFilterConfig) |
Deprecated.
A filter specifying bugs to exclude from being reported.
|
void |
setExtraArgs(Collection<String> extraArgs) |
Deprecated.
Any additional arguments (not covered here more explicitly like
effort ) to be passed along to FindBugs. |
void |
setFindbugsClasspath(FileCollection findbugsClasspath) |
Deprecated.
Class path holding the FindBugs library.
|
void |
setIgnoreFailures(boolean ignoreFailures) |
Deprecated.
Whether to allow the build to continue if there are warnings.
|
void |
setIncludeFilter(File filter) |
Deprecated.
The filename of a filter specifying which bugs are reported.
|
void |
setIncludeFilterConfig(TextResource includeFilterConfig) |
Deprecated.
A filter specifying which bugs are reported.
|
void |
setJvmArgs(Collection<String> jvmArgs) |
Deprecated.
Any additional arguments to be passed along to FindBugs JVM process.
|
void |
setMaxHeapSize(String maxHeapSize) |
Deprecated.
The maximum heap size for the forked findbugs process (ex: '1g').
|
void |
setOmitVisitors(Collection<String> omitVisitors) |
Deprecated.
Similar to
visitors except that it specifies bug detectors which should not be run. |
void |
setPluginClasspath(FileCollection pluginClasspath) |
Deprecated.
Class path holding any additional FindBugs plugins.
|
void |
setReportLevel(String reportLevel) |
Deprecated.
The priority threshold for reporting bugs.
|
void |
setShowProgress(boolean showProgress) |
Deprecated.
Indicates whether analysis progress should be rendered on standard output.
|
void |
setVisitors(Collection<String> visitors) |
Deprecated.
The bug detectors which should be run.
|
exclude, exclude, exclude, exclude, getExcludes, getIncludes, getPatternSetFactory, include, include, include, include, setExcludes, setIncludes, setSource, setSource, source
conventionMapping, conventionMapping, getConventionMapping
newInputDirectory, newInputFile, newOutputDirectory, newOutputFile
appendParallelSafeAction, compareTo, configure, dependsOn, doFirst, doFirst, doFirst, doLast, doLast, doLast, finalizedBy, getActions, getAnt, getAsDynamicObject, getConvention, getDependsOn, getDescription, getDestroyables, getDidWork, getEnabled, getExtensions, getFinalizedBy, getGroup, getIdentityPath, getImpliesSubProjects, getInputs, getLocalState, getLogger, getLogging, getMustRunAfter, getName, getOnlyIf, getOutputs, getPath, getProject, getServices, getShouldRunAfter, getStandardOutputCapture, getState, getTaskActions, getTaskDependencies, getTaskIdentity, getTemporaryDir, getTemporaryDirFactory, getTimeout, hasProperty, hasTaskActions, injectIntoNewInstance, isEnabled, isHasCustomActions, mustRunAfter, onlyIf, onlyIf, prependParallelSafeAction, property, replaceLogger, setActions, setDependsOn, setDescription, setDidWork, setEnabled, setFinalizedBy, setGroup, setImpliesSubProjects, setMustRunAfter, setOnlyIf, setOnlyIf, setProperty, setShouldRunAfter, shouldRunAfter, toString
@Inject protected ObjectFactory getObjectFactory()
@Inject public org.gradle.process.internal.worker.WorkerProcessFactory getWorkerProcessBuilderFactory()
public FindBugsReports getReports()
getReports
in interface Reporting<FindBugsReports>
public FindBugsReports reports(Closure closure)
findbugsTask { reports { xml { destination "build/findbugs.xml" } } }
reports
in interface Reporting<FindBugsReports>
closure
- The configurationpublic FindBugsReports reports(Action<? super FindBugsReports> configureAction)
findbugsTask { reports { xml { destination "build/findbugs.xml" } } }
reports
in interface Reporting<FindBugsReports>
configureAction
- The configuration@Internal @Nullable public File getIncludeFilter()
public void setIncludeFilter(File filter)
@Nullable @Internal public File getExcludeFilter()
public void setExcludeFilter(File filter)
@Nullable @Internal public File getExcludeBugsFilter()
public void setExcludeBugsFilter(File filter)
public void run() throws IOException, InterruptedException
IOException
InterruptedException
public FindBugs extraArgs(Iterable<String> arguments)
effort
) to be passed along to FindBugs. Extra arguments are passed to FindBugs after the arguments Gradle understands
(like effort
but before the list of classes to analyze. This should only be used for arguments that cannot be provided by Gradle directly. Gradle does not try to interpret or validate
the arguments before passing them to FindBugs.
See the FindBugs TextUICommandLine source for available options.
public FindBugs extraArgs(String... arguments)
effort
) to be passed along to FindBugs. Extra arguments are passed to FindBugs after the arguments Gradle understands
(like effort
but before the list of classes to analyze. This should only be used for arguments that cannot be provided by Gradle directly. Gradle does not try to interpret or validate
the arguments before passing them to FindBugs.
See the FindBugs TextUICommandLine source for available options.
@Incubating public FindBugs jvmArgs(Iterable<String> arguments)
Arguments can contain general JVM flags like -Xdebug
and also FindBugs system properties like -Dfindbugs.loadPropertiesFrom=...
@Incubating public FindBugs jvmArgs(String... arguments)
Arguments can contain general JVM flags like -Xdebug
and also FindBugs system properties like -Dfindbugs.loadPropertiesFrom=...
@PathSensitive(RELATIVE) public FileTree getSource()
The PathSensitivity
for the sources is configured to be PathSensitivity.ABSOLUTE
.
If your sources are less strict, please change it accordingly by overriding this method in your subclass.
getSource
in class SourceTask
@SkipWhenEmpty @PathSensitive(RELATIVE) @InputFiles protected FileCollection getCandidateClassFiles()
@Internal public FileCollection getClasses()
public void setClasses(FileCollection classes)
@Classpath public FileCollection getClasspath()
public void setClasspath(FileCollection classpath)
@Classpath public FileCollection getFindbugsClasspath()
public void setFindbugsClasspath(FileCollection findbugsClasspath)
@Classpath public FileCollection getPluginClasspath()
public void setPluginClasspath(FileCollection pluginClasspath)
public boolean getIgnoreFailures()
getIgnoreFailures
in interface VerificationTask
public void setIgnoreFailures(boolean ignoreFailures)
setIgnoreFailures
in interface VerificationTask
ignoreFailures
- false to break the build on failure, true to ignore the failures. The default is false.@Nullable @Optional @Input public String getEffort()
min
, default
, or max
. Higher levels increase precision and find more bugs at the expense of running time
and memory consumption.public void setEffort(@Nullable String effort)
min
, default
, or max
. Higher levels increase precision and find more bugs at the expense of running time
and memory consumption.@Nullable @Optional @Input public String getReportLevel()
low
, all bugs are reported. If set to medium
(the default), medium and high priority bugs are reported. If set to
high
, only high priority bugs are reported.public void setReportLevel(@Nullable String reportLevel)
low
, all bugs are reported. If set to medium
(the default), medium and high priority bugs are reported. If set to
high
, only high priority bugs are reported.@Nullable @Optional @Input public String getMaxHeapSize()
public void setMaxHeapSize(@Nullable String maxHeapSize)
@Nullable @Optional @Input public Collection<String> getVisitors()
public void setVisitors(@Nullable Collection<String> visitors)
@Nullable @Optional @Input public Collection<String> getOmitVisitors()
visitors
except that it specifies bug detectors which should not be run. By default, no visitors are omitted.public void setOmitVisitors(@Nullable Collection<String> omitVisitors)
visitors
except that it specifies bug detectors which should not be run. By default, no visitors are omitted.@Nullable @Optional public TextResource getIncludeFilterConfig()
includeFilter
property.public void setIncludeFilterConfig(@Nullable TextResource includeFilterConfig)
includeFilter
property.@Nullable @Optional public TextResource getExcludeFilterConfig()
excludeFilter
property.public void setExcludeFilterConfig(@Nullable TextResource excludeFilterConfig)
excludeFilter
property.@Nullable @Optional public TextResource getExcludeBugsFilterConfig()
public void setExcludeBugsFilterConfig(@Nullable TextResource excludeBugsFilterConfig)
@Nullable @Optional @Input public Collection<String> getExtraArgs()
effort
) to be passed along to FindBugs. Extra arguments are passed to FindBugs after the arguments Gradle understands
(like effort
but before the list of classes to analyze. This should only be used for arguments that cannot be provided by Gradle directly. Gradle does not try to interpret or validate
the arguments before passing them to FindBugs.
See the FindBugs TextUICommandLine source for available options.
public void setExtraArgs(@Nullable Collection<String> extraArgs)
effort
) to be passed along to FindBugs. Extra arguments are passed to FindBugs after the arguments Gradle understands
(like effort
but before the list of classes to analyze. This should only be used for arguments that cannot be provided by Gradle directly. Gradle does not try to interpret or validate
the arguments before passing them to FindBugs.
See the FindBugs TextUICommandLine source for available options.
@Input public boolean getShowProgress()
public void setShowProgress(boolean showProgress)
@Incubating @Nullable @Optional @Input public Collection<String> getJvmArgs()
Arguments can contain general JVM flags like -Xdebug
and also FindBugs system properties like -Dfindbugs.loadPropertiesFrom=...
@Incubating public void setJvmArgs(@Nullable Collection<String> jvmArgs)
Arguments can contain general JVM flags like -Xdebug
and also FindBugs system properties like -Dfindbugs.loadPropertiesFrom=...