diff options
author | Geir Storli <geirst@yahooinc.com> | 2023-01-04 16:42:55 +0000 |
---|---|---|
committer | Geir Storli <geirst@yahooinc.com> | 2023-01-04 16:42:55 +0000 |
commit | f9575493a0653235b9fd3022b9fd25b9fd271829 (patch) | |
tree | 1a82600254db8100fd6cde62d00c4c6bdf6084a1 /searchlib | |
parent | 91255325ec7029f4a7adfb9491500a2b1c6ec03a (diff) |
Extract virtual fields in the index environment.
Fields that are represented by a set of attributes in the backend are considered virtual fields.
Currently, this is map or array of struct fields (from the SD file) with struct-field attributes.
Diffstat (limited to 'searchlib')
-rw-r--r-- | searchlib/src/vespa/searchcommon/common/datatype.cpp | 4 | ||||
-rw-r--r-- | searchlib/src/vespa/searchcommon/common/datatype.h | 6 | ||||
-rw-r--r-- | searchlib/src/vespa/searchlib/fef/fieldtype.h | 3 |
3 files changed, 9 insertions, 4 deletions
diff --git a/searchlib/src/vespa/searchcommon/common/datatype.cpp b/searchlib/src/vespa/searchcommon/common/datatype.cpp index 1fe3a488aac..7088bae9e48 100644 --- a/searchlib/src/vespa/searchcommon/common/datatype.cpp +++ b/searchlib/src/vespa/searchcommon/common/datatype.cpp @@ -25,6 +25,7 @@ dataTypeFromName(vespalib::stringref name) { else if (name == "BOOLEANTREE") { return DataType::BOOLEANTREE; } else if (name == "TENSOR") { return DataType::TENSOR; } else if (name == "REFERENCE") { return DataType::REFERENCE; } + else if (name == "COMBINED") { return DataType::COMBINED; } else { throw InvalidConfigException("Illegal enum value '" + name + "'"); } @@ -44,7 +45,8 @@ const char *datatype_str[] = { "BOOL", "FEATURE_NOTUSED", "BOOLEANTREE", "TENSOR", - "REFERENCE"}; + "REFERENCE", + "COMBINED"}; vespalib::string getTypeName(DataType type) { diff --git a/searchlib/src/vespa/searchcommon/common/datatype.h b/searchlib/src/vespa/searchcommon/common/datatype.h index e1c6a44b620..b7a0cc53e37 100644 --- a/searchlib/src/vespa/searchcommon/common/datatype.h +++ b/searchlib/src/vespa/searchcommon/common/datatype.h @@ -24,13 +24,15 @@ enum class DataType { //FEATURE = 11, BOOLEANTREE = 12, TENSOR = 13, - REFERENCE = 14 + REFERENCE = 14, + COMBINED = 15 }; /** * Collection type for a field. **/ -enum class CollectionType { SINGLE = 0, +enum class CollectionType { + SINGLE = 0, ARRAY = 1, WEIGHTEDSET = 2 }; diff --git a/searchlib/src/vespa/searchlib/fef/fieldtype.h b/searchlib/src/vespa/searchlib/fef/fieldtype.h index e103863e4d9..4d4dafa6414 100644 --- a/searchlib/src/vespa/searchlib/fef/fieldtype.h +++ b/searchlib/src/vespa/searchlib/fef/fieldtype.h @@ -10,7 +10,8 @@ namespace search::fef { enum class FieldType { INDEX = 1, ATTRIBUTE = 2, - HIDDEN_ATTRIBUTE = 3 + HIDDEN_ATTRIBUTE = 3, + VIRTUAL = 4 }; } |