diff options
author | Tor Egge <Tor.Egge@oath.com> | 2018-09-05 14:20:57 +0000 |
---|---|---|
committer | Tor Egge <Tor.Egge@oath.com> | 2018-09-06 08:30:06 +0000 |
commit | 61ec01d27f00171f0029840f8f71eb395921d1c2 (patch) | |
tree | c4da38684281bda0e67f63007afc750353f65390 | |
parent | c1fdecf3cb26f1a3aef2caf290916a4f533c6c58 (diff) |
Add virtual method to differentiate between AttributeNode and upcoming
AttributeKeyedNode.
Allow override of cleanup() method.
-rw-r--r-- | searchlib/src/vespa/searchlib/expression/attributenode.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/searchlib/src/vespa/searchlib/expression/attributenode.h b/searchlib/src/vespa/searchlib/expression/attributenode.h index 3cbccd32e60..3b1db5f8651 100644 --- a/searchlib/src/vespa/searchlib/expression/attributenode.h +++ b/searchlib/src/vespa/searchlib/expression/attributenode.h @@ -55,6 +55,7 @@ public: void useEnumOptimization(bool use=true) { _useEnumOptimization = use; } bool hasMultiValue() const { return _hasMultiValue; } + virtual bool isKeyed() const { return false; } protected: class Handler { @@ -68,7 +69,7 @@ private: class StringHandler; class EnumHandler; protected: - void cleanup(); + virtual void cleanup(); void wireAttributes(const search::attribute::IAttributeContext & attrCtx) override; void onPrepare(bool preserveAccurateTypes) override; bool onExecute() const override; |