Class CheckstyleReportGenerator
- java.lang.Object
-
- org.apache.maven.plugins.checkstyle.CheckstyleReportGenerator
-
public class CheckstyleReportGenerator extends java.lang.ObjectGenerate a report based on CheckstyleResults.
-
-
Constructor Summary
Constructors Constructor Description CheckstyleReportGenerator(Sink sink, java.util.ResourceBundle bundle, java.io.File basedir, SiteTool siteTool, java.lang.String ruleset)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidgenerateReport(CheckstyleResults results)ConfigurationgetCheckstyleConfig()LoggetLog()SeverityLevelgetSeverityLevel()java.util.List<java.lang.String>getTreeWalkerNames()java.lang.StringgetXrefLocation()booleanisEnableFilesSummary()booleanisEnableRSS()booleanisEnableRulesSummary()booleanisEnableSeveritySummary()booleanmatchRule(AuditEvent event, java.lang.String ruleName, java.lang.String expectedMessage, java.lang.String expectedSeverity)Check if a violation matches a rule.voidsetCheckstyleConfig(Configuration config)voidsetEnableFilesSummary(boolean enableFilesSummary)voidsetEnableRSS(boolean enableRSS)voidsetEnableRulesSummary(boolean enableRulesSummary)voidsetEnableSeveritySummary(boolean enableSeveritySummary)voidsetLog(Log log)voidsetSeverityLevel(SeverityLevel severityLevel)voidsetTreeWalkerNames(java.util.List<java.lang.String> treeWalkerNames)voidsetXrefLocation(java.lang.String xrefLocation)java.util.List<org.apache.maven.plugins.checkstyle.CheckstyleReportGenerator.ConfReference>sortConfiguration(CheckstyleResults results)
-
-
-
Method Detail
-
getLog
public Log getLog()
-
setLog
public void setLog(Log log)
-
generateReport
public void generateReport(CheckstyleResults results)
-
matchRule
public boolean matchRule(AuditEvent event, java.lang.String ruleName, java.lang.String expectedMessage, java.lang.String expectedSeverity)
Check if a violation matches a rule.- Parameters:
event- the violation to checkruleName- The name of the ruleexpectedMessage- A message that, if it's not null, will be matched to the message from the violationexpectedSeverity- A severity that, if it's not null, will be matched to the severity from the violation- Returns:
- The number of rule violations
-
getSeverityLevel
public SeverityLevel getSeverityLevel()
-
setSeverityLevel
public void setSeverityLevel(SeverityLevel severityLevel)
-
isEnableRulesSummary
public boolean isEnableRulesSummary()
-
setEnableRulesSummary
public void setEnableRulesSummary(boolean enableRulesSummary)
-
isEnableSeveritySummary
public boolean isEnableSeveritySummary()
-
setEnableSeveritySummary
public void setEnableSeveritySummary(boolean enableSeveritySummary)
-
isEnableFilesSummary
public boolean isEnableFilesSummary()
-
setEnableFilesSummary
public void setEnableFilesSummary(boolean enableFilesSummary)
-
isEnableRSS
public boolean isEnableRSS()
-
setEnableRSS
public void setEnableRSS(boolean enableRSS)
-
getXrefLocation
public java.lang.String getXrefLocation()
-
setXrefLocation
public void setXrefLocation(java.lang.String xrefLocation)
-
getCheckstyleConfig
public Configuration getCheckstyleConfig()
-
setCheckstyleConfig
public void setCheckstyleConfig(Configuration config)
-
setTreeWalkerNames
public void setTreeWalkerNames(java.util.List<java.lang.String> treeWalkerNames)
-
getTreeWalkerNames
public java.util.List<java.lang.String> getTreeWalkerNames()
-
sortConfiguration
public java.util.List<org.apache.maven.plugins.checkstyle.CheckstyleReportGenerator.ConfReference> sortConfiguration(CheckstyleResults results)
-
-