diff options
author | Stephane Gamard <stephane.gamard@searchbox.com> | 2014-05-01 16:56:12 +0200 |
---|---|---|
committer | Stephane Gamard <stephane.gamard@searchbox.com> | 2014-05-01 17:55:27 +0200 |
commit | df878fb7758cd49968cdfe4ff339cc0a4692ea6f (patch) | |
tree | a4d28e591b2b11388dbf8e414ec8de8087e08533 | |
parent | 88901f2f7deacb7103253be9b6f583eb77333df1 (diff) | |
download | sonarqube-df878fb7758cd49968cdfe4ff339cc0a4692ea6f.tar.gz sonarqube-df878fb7758cd49968cdfe4ff339cc0a4692ea6f.zip |
SONAR-5237 - Added RuleParam
-rw-r--r-- | sonar-server/src/main/java/org/sonar/server/rule2/RuleDoc.java | 3 | ||||
-rw-r--r-- | sonar-server/src/main/java/org/sonar/server/rule2/RuleIndex.java | 6 |
2 files changed, 8 insertions, 1 deletions
diff --git a/sonar-server/src/main/java/org/sonar/server/rule2/RuleDoc.java b/sonar-server/src/main/java/org/sonar/server/rule2/RuleDoc.java index 48402175569..4cb290b6180 100644 --- a/sonar-server/src/main/java/org/sonar/server/rule2/RuleDoc.java +++ b/sonar-server/src/main/java/org/sonar/server/rule2/RuleDoc.java @@ -95,7 +95,8 @@ class RuleDoc implements Rule { @Override public List<RuleParam> params() { - throw new UnsupportedOperationException("TODO"); + RuleParam param = new RuleParam() + } @Override diff --git a/sonar-server/src/main/java/org/sonar/server/rule2/RuleIndex.java b/sonar-server/src/main/java/org/sonar/server/rule2/RuleIndex.java index 1c045f93aac..35c59ffd770 100644 --- a/sonar-server/src/main/java/org/sonar/server/rule2/RuleIndex.java +++ b/sonar-server/src/main/java/org/sonar/server/rule2/RuleIndex.java @@ -66,6 +66,7 @@ public class RuleIndex extends BaseIndex<RuleKey, RuleDto> { RuleField.SYSTEM_TAGS.key(), RuleField.CREATED_AT.key(), RuleField.REPOSITORY.key(), + RuleField.PARAMS.key(), RuleField.UPDATED_AT.key()); public RuleIndex(RuleNormalizer normalizer, WorkQueue workQueue, @@ -173,6 +174,11 @@ public class RuleIndex extends BaseIndex<RuleKey, RuleDto> { .field("dynamic", true) .endObject(); + mapping.startObject("params") + .field("type", "nested") + .field("dynamic", true) + .endObject(); + return mapping.endObject() .endObject().endObject(); } |