aboutsummaryrefslogtreecommitdiffstats
path: root/searchlib/src/vespa/searchlib/predicate/predicate_zero_constraint_posting_list.h
blob: 1cfc50091ccf2441145f60eeb203a07585189eb4 (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
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.

#pragma once

#include "predicate_posting_list.h"
#include "common.h"

namespace search::predicate {

/**
 * PredicatePostingList implementation for zero constraint documents
 * from PredicateIndex.
 */
class PredicateZeroConstraintPostingList : public PredicatePostingList {
    using Iterator = ZeroConstraintDocs::Iterator;
    Iterator _iterator;

public:
    PredicateZeroConstraintPostingList(Iterator it);
    bool next(uint32_t doc_id) override;
    bool nextInterval() override { return false; }
    VESPA_DLL_LOCAL uint32_t getInterval() const override { return 0x00010001; }
};

}