public class CheckstyleExtension extends CodeQualityExtension
CheckstylePlugin
Constructor | Description |
---|---|
CheckstyleExtension(Project project) |
Modifier and Type | Method | Description |
---|---|---|
TextResource |
getConfig() |
The Checkstyle configuration to use.
|
File |
getConfigFile() |
The Checkstyle configuration file to use.
|
Map<String,Object> |
getConfigProperties() |
The properties available for use in the configuration file.
|
int |
getMaxErrors() |
The maximum number of errors that are tolerated before breaking the build
or setting the failure property.
|
int |
getMaxWarnings() |
The maximum number of warnings that are tolerated before breaking the build
or setting the failure property.
|
boolean |
isShowViolations() |
Whether or not rule violations are to be displayed on the console.
|
void |
setConfig(TextResource config) |
|
void |
setConfigFile(File configFile) |
The Checkstyle configuration file to use.
|
void |
setConfigProperties(Map<String,Object> configProperties) |
|
void |
setMaxErrors(int maxErrors) |
Set the maximum number of errors that are tolerated before breaking the build.
|
void |
setMaxWarnings(int maxWarnings) |
Set the maximum number of warnings that are tolerated before breaking the build.
|
void |
setShowViolations(boolean showViolations) |
getReportsDir, getSourceSets, getToolVersion, isIgnoreFailures, setIgnoreFailures, setReportsDir, setSourceSets, setToolVersion
public CheckstyleExtension(Project project)
public File getConfigFile()
@Incubating public TextResource getConfig()
configFile
property.public void setConfigFile(File configFile)
public void setConfig(TextResource config)
public Map<String,Object> getConfigProperties()
public int getMaxErrors()
Example: maxErrors = 42
public void setMaxErrors(int maxErrors)
maxErrors
- number of errors allowedpublic int getMaxWarnings()
Example: maxWarnings = 1000
public void setMaxWarnings(int maxWarnings)
maxWarnings
- number of warnings allowedpublic boolean isShowViolations()
public void setShowViolations(boolean showViolations)