aboutsummaryrefslogtreecommitdiffstats
path: root/sonar-plugin-api/src
diff options
context:
space:
mode:
authorSimon Brandhof <simon.brandhof@sonarsource.com>2017-05-25 18:01:53 +0200
committerEric Hartmann <hartmann.eric@gmail.com>2017-06-14 15:43:12 +0200
commitb6dd52cf7cd8c47988cfdb9a9887ac4e66c61999 (patch)
treea213f78b671403f4046c05c47f790d8955514d54 /sonar-plugin-api/src
parent3618f6417ade2a02a139c99b2add0967ca647288 (diff)
downloadsonarqube-b6dd52cf7cd8c47988cfdb9a9887ac4e66c61999.tar.gz
sonarqube-b6dd52cf7cd8c47988cfdb9a9887ac4e66c61999.zip
SONAR-9322 deprecate RulesProfile#setParentName(String)
Hierarchy of profiles in plugin API has never been implemented. The method is misleading so it's marked as deprecated.
Diffstat (limited to 'sonar-plugin-api/src')
-rw-r--r--sonar-plugin-api/src/main/java/org/sonar/api/profiles/RulesProfile.java17
1 files changed, 9 insertions, 8 deletions
diff --git a/sonar-plugin-api/src/main/java/org/sonar/api/profiles/RulesProfile.java b/sonar-plugin-api/src/main/java/org/sonar/api/profiles/RulesProfile.java
index 01e1307210d..36e058071dd 100644
--- a/sonar-plugin-api/src/main/java/org/sonar/api/profiles/RulesProfile.java
+++ b/sonar-plugin-api/src/main/java/org/sonar/api/profiles/RulesProfile.java
@@ -64,7 +64,6 @@ public class RulesProfile implements Cloneable {
private String name;
private Boolean defaultProfile = Boolean.FALSE;
private String language;
- private String parentName;
private List<ActiveRule> activeRules = new ArrayList<>();
/**
@@ -217,22 +216,25 @@ public class RulesProfile implements Cloneable {
}
/**
- * For internal use only.
+ * Does nothing.
*
- * @since 2.5
+ * @return {@code null}
+ * @deprecated in 6.5
*/
+ @Deprecated
@CheckForNull
public String getParentName() {
- return parentName;
+ return null;
}
/**
- * For internal use only.
+ * Does nothing.
*
- * @since 2.5
+ * @deprecated in 6.5
*/
+ @Deprecated
public void setParentName(String parentName) {
- this.parentName = parentName;
+ // does nothing
}
/**
@@ -338,7 +340,6 @@ public class RulesProfile implements Cloneable {
public Object clone() {
RulesProfile clone = RulesProfile.create(getName(), getLanguage());
clone.setDefaultProfile(getDefaultProfile());
- clone.setParentName(getParentName());
if (activeRules != null && !activeRules.isEmpty()) {
clone.setActiveRules(Lists.transform(activeRules, CloneFunction.INSTANCE));
}