Package org.sonar.api.rules
Class ActiveRule
- java.lang.Object
-
- org.sonar.api.rules.ActiveRule
-
- All Implemented Interfaces:
java.lang.Cloneable
public class ActiveRule extends java.lang.Object implements java.lang.Cloneable
-
-
Constructor Summary
Constructors Constructor Description ActiveRule()Deprecated.visibility should be reduced to protected or packageActiveRule(RulesProfile profile, Rule rule, RulePriority severity)Deprecated.visibility should be reduced to protected or package
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description java.lang.Objectclone()booleandoesOverride()booleanequals(java.lang.Object o)java.util.List<ActiveRuleParam>getActiveRuleParams()java.lang.StringgetConfigKey()java.lang.IntegergetId()java.lang.StringgetInheritance()For internal use only.RulePrioritygetOverriddenSeverity()Deprecated.since 6.6, internal usage onlyjava.lang.StringgetParameter(java.lang.String key)java.lang.StringgetPluginName()Deprecated.since 2.3 usegetRepositoryKey()insteadjava.lang.StringgetRepositoryKey()RulegetRule()java.lang.StringgetRuleKey()RulesProfilegetRulesProfile()RulePrioritygetSeverity()inthashCode()booleanisEnabled()booleanisInherited()voidsetActiveRuleParams(java.util.List<ActiveRuleParam> params)Deprecated.use setParameter()voidsetId(java.lang.Integer id)Deprecated.visibility should be decreased to protected or packagevoidsetInheritance(java.lang.String s)For internal use only.ActiveRulesetParameter(java.lang.String key, java.lang.String value)voidsetRule(Rule rule)Deprecated.visibility should be reduced to protected or packagevoidsetRulesProfile(RulesProfile rulesProfile)Deprecated.visibility should be reduced to protected or packagevoidsetSeverity(RulePriority severity)java.lang.StringtoString()
-
-
-
Field Detail
-
INHERITED
public static final java.lang.String INHERITED
- See Also:
- Constant Field Values
-
OVERRIDES
public static final java.lang.String OVERRIDES
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
ActiveRule
@Deprecated public ActiveRule()
Deprecated.visibility should be reduced to protected or package
-
ActiveRule
@Deprecated public ActiveRule(RulesProfile profile, Rule rule, @Nullable RulePriority severity)
Deprecated.visibility should be reduced to protected or package
-
-
Method Detail
-
getId
public java.lang.Integer getId()
-
getInheritance
public java.lang.String getInheritance()
For internal use only.- Since:
- 2.5
-
setInheritance
public void setInheritance(java.lang.String s)
For internal use only.- Since:
- 2.5
-
isInherited
public boolean isInherited()
-
doesOverride
public boolean doesOverride()
-
setId
@Deprecated public void setId(java.lang.Integer id)
Deprecated.visibility should be decreased to protected or package
-
getRule
public Rule getRule()
-
setRule
@Deprecated public void setRule(Rule rule)
Deprecated.visibility should be reduced to protected or package
-
getSeverity
public RulePriority getSeverity()
- Since:
- 2.5
-
getOverriddenSeverity
@Deprecated public RulePriority getOverriddenSeverity()
Deprecated.since 6.6, internal usage onlyFor internal use- Since:
- 6.6
-
setSeverity
public void setSeverity(RulePriority severity)
- Since:
- 2.5
-
getRulesProfile
public RulesProfile getRulesProfile()
-
setRulesProfile
@Deprecated public void setRulesProfile(RulesProfile rulesProfile)
Deprecated.visibility should be reduced to protected or package
-
getActiveRuleParams
public java.util.List<ActiveRuleParam> getActiveRuleParams()
-
setActiveRuleParams
@Deprecated public void setActiveRuleParams(java.util.List<ActiveRuleParam> params)
Deprecated.use setParameter()
-
setParameter
public ActiveRule setParameter(java.lang.String key, java.lang.String value)
-
getParameter
public java.lang.String getParameter(java.lang.String key)
-
getPluginName
@Deprecated public java.lang.String getPluginName()
Deprecated.since 2.3 usegetRepositoryKey()instead
-
getRepositoryKey
public java.lang.String getRepositoryKey()
-
getConfigKey
public java.lang.String getConfigKey()
- Returns:
- the config key the active rule belongs to
-
getRuleKey
public java.lang.String getRuleKey()
- Returns:
- the key of the active rule
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equalsin classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
clone
public java.lang.Object clone()
- Overrides:
clonein classjava.lang.Object
-
isEnabled
public boolean isEnabled()
- Since:
- 2.6
-
-