@groovy.transform.Trait @groovy.transform.CompileStatic trait SpotBugsPluginsTrait extends java.lang.Object
SpotBugs plugin support for Mojos.
| Type Params | Return Type | Name and description |
|---|---|---|
|
java.util.Map<java.lang.String, java.lang.String> |
buildBugTypeUrlMap(java.util.Map<java.lang.String, java.lang.String> userPluginDocUrls)Builds a mapping from bug type codes to their documentation URLs by reading the findbugs.xml descriptor from each resolved SpotBugs plugin JAR. |
|
abstract java.lang.String |
getEffort() |
|
java.lang.String |
getEffortParameter()Returns the effort parameter to use. |
|
abstract RepositorySystem |
getFactory() |
|
abstract Log |
getLog() |
|
abstract java.util.List<Artifact> |
getPluginArtifacts() |
|
abstract java.lang.String |
getPluginList() |
|
abstract java.util.List<PluginArtifact> |
getPlugins() |
|
abstract RepositorySystem |
getRepositorySystem() |
|
abstract org.codehaus.plexus.resource.ResourceManager |
getResourceManager() |
|
abstract MavenSession |
getSession() |
|
java.lang.String |
getSpotbugsPlugins()Adds the specified plugins to spotbugs. |
|
abstract java.io.File |
getSpotbugsXmlOutputDirectory() |
|
boolean |
isSpotBugsPlugin(java.io.File file)Determines whether the given file is a SpotBugs extension plugin by checking if it is a JAR containing findbugs.xml at the root. |
| Methods inherited from class | Name |
|---|---|
class java.lang.Object |
java.lang.Object#equals(java.lang.Object), java.lang.Object#getClass(), java.lang.Object#hashCode(), java.lang.Object#notify(), java.lang.Object#notifyAll(), java.lang.Object#toString(), java.lang.Object#wait(), java.lang.Object#wait(long), java.lang.Object#wait(long, int) |
Builds a mapping from bug type codes to their documentation URLs by reading
the findbugs.xml descriptor from each resolved SpotBugs plugin JAR.
The method inspects JARs from two sources:
pluginList (comma-separated file paths).pluginArtifacts (Maven dependencies).com.mebigfatguy.fbcontrib → fb-contrib / sb-contribcom.h3xstream.findsecbugs → Find Security BugsuserPluginDocUrls override the built-in defaults.
URL templates may contain the placeholder {type} which will be replaced with
the bug type code (e.g. https://example.com/bugs.html#{type}). userPluginDocUrls - optional user-configured map of plugin IDs to URL templatesReturns the effort parameter to use.
Adds the specified plugins to spotbugs. The coreplugin is always added first.
Determines whether the given file is a SpotBugs extension plugin by checking
if it is a JAR containing findbugs.xml at the root.
file - the artifact file to inspecttrue if the file is a SpotBugs plugin JAR, false otherwise