blob: 3e3753e1e0aa2533f20e39c47d8f9e74cefc2945 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
|
// Copyright Vespa.ai. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#pragma once
#include <vespa/juniper/query_item.h>
namespace search { class SimpleQueryStackDumpIterator; }
namespace search::docsummary {
struct JuniperDFWExplicitItemData;
/**
* This struct is used to point to the traversal state located on
* the stack of the IQuery Traverse method. This is needed because
* the Traverse method is const.
**/
class JuniperDFWQueryItem : public juniper::QueryItem
{
search::SimpleQueryStackDumpIterator *_si;
const JuniperDFWExplicitItemData *_data;
public:
JuniperDFWQueryItem() : _si(nullptr), _data(nullptr) {}
~JuniperDFWQueryItem() override = default;
explicit JuniperDFWQueryItem(search::SimpleQueryStackDumpIterator *si) : _si(si), _data(nullptr) {}
explicit JuniperDFWQueryItem(const JuniperDFWExplicitItemData *data) : _si(nullptr), _data(data) {}
JuniperDFWQueryItem(const QueryItem&) = delete;
JuniperDFWQueryItem& operator= (const QueryItem&) = delete;
vespalib::stringref get_index() const override;
int get_weight() const override;
juniper::ItemCreator get_creator() const override;
};
}
|