import java.util.List;
import java.util.stream.Collectors;
import javax.annotation.CheckForNull;
+import javax.annotation.Nullable;
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang.builder.ToStringBuilder;
import org.sonar.api.profiles.RulesProfile;
* @deprecated visibility should be reduced to protected or package
*/
@Deprecated
- public ActiveRule(RulesProfile profile, Rule rule, RulePriority severity) {
+ public ActiveRule(RulesProfile profile, Rule rule, @Nullable RulePriority severity) {
this.rule = rule;
this.overriddenSeverity = severity;
if (severity == null && rule != null) {
* @param severity severity to set, if null, uses the default priority.
* @since 2.5
*/
- public Rule setSeverity(RulePriority severity) {
+ public Rule setSeverity(@Nullable RulePriority severity) {
if (severity == null) {
this.priority = DEFAULT_PRIORITY;
} else {