summaryrefslogtreecommitdiffstats
path: root/searchcommon
diff options
context:
space:
mode:
Diffstat (limited to 'searchcommon')
-rw-r--r--searchcommon/src/vespa/searchcommon/attribute/iattributevector.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/searchcommon/src/vespa/searchcommon/attribute/iattributevector.h b/searchcommon/src/vespa/searchcommon/attribute/iattributevector.h
index edc71591175..331e950879a 100644
--- a/searchcommon/src/vespa/searchcommon/attribute/iattributevector.h
+++ b/searchcommon/src/vespa/searchcommon/attribute/iattributevector.h
@@ -11,6 +11,7 @@
namespace search {
+class IDocumentWeightAttribute;
class QueryTermSimple;
namespace attribute {
@@ -255,6 +256,13 @@ public:
const SearchContextParams &params) const = 0;
/**
+ * Type-safe down-cast to an attribute supporting direct document weight iterators.
+ *
+ * @return document weight attribute or nullptr if not supported.
+ */
+ virtual const IDocumentWeightAttribute *asDocumentWeightAttribute() const = 0;
+
+ /**
* Returns the basic type of this attribute vector.
*
* @return basic type