aboutsummaryrefslogtreecommitdiffstats
path: root/sonar-plugin-api-impl/src
diff options
context:
space:
mode:
authorMichal Duda <michal.duda@sonarsource.com>2020-04-23 20:16:38 +0200
committersonartech <sonartech@sonarsource.com>2020-05-25 20:05:22 +0000
commitbf05b3c7c2e5157047dccefcfb38af0033c77f20 (patch)
treeab4dcbce1ecf30e9782c8ec3bdc56f607ce1e1b0 /sonar-plugin-api-impl/src
parent88e71c8c976210624ddb296f24f2ddcbe53417b4 (diff)
downloadsonarqube-bf05b3c7c2e5157047dccefcfb38af0033c77f20.tar.gz
sonarqube-bf05b3c7c2e5157047dccefcfb38af0033c77f20.zip
SONAR-13221 change PK of RULES and update FK
Diffstat (limited to 'sonar-plugin-api-impl/src')
-rw-r--r--sonar-plugin-api-impl/src/main/java/org/sonar/api/batch/rule/internal/DefaultRule.java7
-rw-r--r--sonar-plugin-api-impl/src/main/java/org/sonar/api/batch/rule/internal/NewRule.java8
2 files changed, 1 insertions, 14 deletions
diff --git a/sonar-plugin-api-impl/src/main/java/org/sonar/api/batch/rule/internal/DefaultRule.java b/sonar-plugin-api-impl/src/main/java/org/sonar/api/batch/rule/internal/DefaultRule.java
index 0acee4c0a30..5915ff716ce 100644
--- a/sonar-plugin-api-impl/src/main/java/org/sonar/api/batch/rule/internal/DefaultRule.java
+++ b/sonar-plugin-api-impl/src/main/java/org/sonar/api/batch/rule/internal/DefaultRule.java
@@ -34,7 +34,6 @@ import org.sonar.api.rule.RuleStatus;
public class DefaultRule implements Rule {
private final RuleKey key;
- private final Integer id;
private final String name;
private final String severity;
private final String type;
@@ -45,7 +44,6 @@ public class DefaultRule implements Rule {
public DefaultRule(NewRule newRule) {
this.key = newRule.key;
- this.id = newRule.id;
this.name = newRule.name;
this.severity = newRule.severity;
this.type = newRule.type;
@@ -65,11 +63,6 @@ public class DefaultRule implements Rule {
return key;
}
- @CheckForNull
- public Integer id() {
- return id;
- }
-
@Override
public String name() {
return name;
diff --git a/sonar-plugin-api-impl/src/main/java/org/sonar/api/batch/rule/internal/NewRule.java b/sonar-plugin-api-impl/src/main/java/org/sonar/api/batch/rule/internal/NewRule.java
index 3cef62bbf2f..116f82621a8 100644
--- a/sonar-plugin-api-impl/src/main/java/org/sonar/api/batch/rule/internal/NewRule.java
+++ b/sonar-plugin-api-impl/src/main/java/org/sonar/api/batch/rule/internal/NewRule.java
@@ -33,7 +33,6 @@ public class NewRule {
private static final String DEFAULT_SEVERITY = Severity.defaultSeverity();
final RuleKey key;
- Integer id;
String name;
String description;
String severity = DEFAULT_SEVERITY;
@@ -46,11 +45,6 @@ public class NewRule {
this.key = key;
}
- public NewRule setId(@Nullable Integer id) {
- this.id = id;
- return this;
- }
-
public NewRule setDescription(@Nullable String description) {
this.description = description;
return this;
@@ -65,7 +59,7 @@ public class NewRule {
this.severity = StringUtils.defaultIfBlank(severity, DEFAULT_SEVERITY);
return this;
}
-
+
public NewRule setType(@Nullable String type) {
this.type = type;
return this;