summaryrefslogtreecommitdiffstats
path: root/config-model
diff options
context:
space:
mode:
authorArne Juul <arnej@yahoo-inc.com>2018-11-23 07:38:03 +0000
committergjoranv <gv@oath.com>2019-01-21 15:09:29 +0100
commitb0c516e100c9618fdc6bdca9a76717477d442a35 (patch)
treea052718d2b72b00e93375e0a1d327936d166f2cf /config-model
parent40b5f3906a82c2d333272517f1e326e4357c50d2 (diff)
remove unused code
Diffstat (limited to 'config-model')
-rw-r--r--config-model/src/main/java/com/yahoo/searchdefinition/Index.java19
-rw-r--r--config-model/src/main/java/com/yahoo/searchdefinition/derived/IndexInfo.java19
2 files changed, 0 insertions, 38 deletions
diff --git a/config-model/src/main/java/com/yahoo/searchdefinition/Index.java b/config-model/src/main/java/com/yahoo/searchdefinition/Index.java
index 59f97a7e535..1620c90acd1 100644
--- a/config-model/src/main/java/com/yahoo/searchdefinition/Index.java
+++ b/config-model/src/main/java/com/yahoo/searchdefinition/Index.java
@@ -51,9 +51,6 @@ public class Index implements Cloneable, Serializable {
/** Whether the content of this index is normalized */
private boolean normalized=true;
- /** The set of all searchable fields which should be searched with this index. May not null */
- public Set<String> matchGroup=new LinkedHashSet<>();
-
private Type type = Type.VESPA;
/** The boolean index definition, if set */
@@ -82,22 +79,6 @@ public class Index implements Cloneable, Serializable {
public Stemming getStemming() { return stemming; }
/**
- * Returns the (unmodifiable) set of searchable fields which should be searched
- * when this index is searched. This is useful to specify that some attributes should be
- * searched as well when an index is searched.
- * This set is either empty, or if set contains both the name of this index, and some other
- * indexes.
- */
- public Set<String> getMatchGroup() { return Collections.unmodifiableSet(matchGroup); }
-
- /** Adds a searchable field name to be searched when this index is searched */
- public void addToMatchGroup(String name) {
- if (name.equals(this.name)) return;
- if (matchGroup.size()==0) matchGroup.add(this.name);
- matchGroup.add(name);
- }
-
- /**
* Whether this field should be stemmed in this search definition,
* this is never null
*/
diff --git a/config-model/src/main/java/com/yahoo/searchdefinition/derived/IndexInfo.java b/config-model/src/main/java/com/yahoo/searchdefinition/derived/IndexInfo.java
index 7b84ab5b873..a807cc79d95 100644
--- a/config-model/src/main/java/com/yahoo/searchdefinition/derived/IndexInfo.java
+++ b/config-model/src/main/java/com/yahoo/searchdefinition/derived/IndexInfo.java
@@ -27,7 +27,6 @@ public class IndexInfo extends Derived implements IndexInfoConfig.Producer {
private static final String CMD_HIGHLIGHT = "highlight";
private static final String CMD_INDEX = "index";
private static final String CMD_LOWERCASE = "lowercase";
- private static final String CMD_MATCH_GROUP = "match-group ";
private static final String CMD_NORMALIZE = "normalize";
private static final String CMD_STEM = "stem";
private static final String CMD_URLHOST = "urlhost";
@@ -76,24 +75,6 @@ public class IndexInfo extends Derived implements IndexInfoConfig.Producer {
}
}
- @Override
- protected void derive(Index index, Search search) {
- if (index.getMatchGroup().size() > 0) {
- addIndexCommand(index.getName(), CMD_MATCH_GROUP + toSpaceSeparated(index.getMatchGroup()));
- }
- }
-
- private String toSpaceSeparated(Collection c) {
- StringBuffer b = new StringBuffer();
- for (Iterator i = c.iterator(); i.hasNext();) {
- b.append(i.next());
- if (i.hasNext()) {
- b.append(" ");
- }
- }
- return b.toString();
- }
-
private static boolean isPositionArrayField(ImmutableSDField field) {
return field.getDataType().equals(DataType.getArray(PositionDataType.INSTANCE));
}