Class DefaultActiveRule
- java.lang.Object
-
- org.sonar.api.batch.rule.internal.DefaultActiveRule
-
- All Implemented Interfaces:
ActiveRule
@Immutable public class DefaultActiveRule extends java.lang.Object implements ActiveRule
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description longcreatedAt()java.lang.StringinternalKey()Optional key declared and used by the underlying rule engine.java.lang.Stringlanguage()Language of rule, for examplejavajava.lang.Stringparam(java.lang.String key)Value of given parameter.java.util.Map<java.lang.String,java.lang.String>params()Immutable parameter values.java.lang.StringqpKey()Key of the quality profile the rule belongs to.RuleKeyruleKey()java.lang.Stringseverity()Non-null severity.java.lang.StringtemplateRuleKey()Optional rule key of the template rule.longupdatedAt()
-
-
-
Method Detail
-
ruleKey
public RuleKey ruleKey()
- Specified by:
ruleKeyin interfaceActiveRule
-
severity
public java.lang.String severity()
Description copied from interface:ActiveRuleNon-null severity.- Specified by:
severityin interfaceActiveRule- See Also:
Severity
-
language
public java.lang.String language()
Description copied from interface:ActiveRuleLanguage of rule, for examplejava- Specified by:
languagein interfaceActiveRule
-
param
public java.lang.String param(java.lang.String key)
Description copied from interface:ActiveRuleValue of given parameter. Returnsnullif the parameter key does not exist on the rule or if the parameter has no value nor default value.- Specified by:
paramin interfaceActiveRule
-
params
public java.util.Map<java.lang.String,java.lang.String> params()
Description copied from interface:ActiveRuleImmutable parameter values. Returns an empty map if no parameters are defined.- Specified by:
paramsin interfaceActiveRule
-
internalKey
public java.lang.String internalKey()
Description copied from interface:ActiveRuleOptional key declared and used by the underlying rule engine. As an example the key of a Checkstyle rule looks likecom.puppycrawl.tools.checkstyle.checks.FooCheckwhereas its internal key can beChecker/TreeWalker/Foo.- Specified by:
internalKeyin interfaceActiveRule
-
templateRuleKey
public java.lang.String templateRuleKey()
Description copied from interface:ActiveRuleOptional rule key of the template rule.- Specified by:
templateRuleKeyin interfaceActiveRule
-
createdAt
public long createdAt()
-
updatedAt
public long updatedAt()
-
qpKey
public java.lang.String qpKey()
Description copied from interface:ActiveRuleKey of the quality profile the rule belongs to.- Specified by:
qpKeyin interfaceActiveRule
-
-