Branch data Line data Source code
1 : : /** @file postlist.cc
2 : : * @brief Abstract base class for postlists.
3 : : */
4 : : /* Copyright (C) 2007,2009,2011,2015,2017 Olly Betts
5 : : *
6 : : * This program is free software; you can redistribute it and/or
7 : : * modify it under the terms of the GNU General Public License as
8 : : * published by the Free Software Foundation; either version 2 of the
9 : : * License, or (at your option) any later version.
10 : : *
11 : : * This program is distributed in the hope that it will be useful,
12 : : * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 : : * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 : : * GNU General Public License for more details.
15 : : *
16 : : * You should have received a copy of the GNU General Public License
17 : : * along with this program; if not, write to the Free Software
18 : : * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 : : */
20 : :
21 : : #include <config.h>
22 : :
23 : : #include "postlist.h"
24 : :
25 : : #include <xapian/error.h>
26 : :
27 : : #include "omassert.h"
28 : :
29 : : using namespace std;
30 : :
31 [ - + ]: 963646 : PostList::~PostList() {}
32 : :
33 : : TermFreqs
34 : 0 : PostList::get_termfreq_est_using_stats(const Xapian::Weight::Internal &) const
35 : : {
36 : : throw Xapian::InvalidOperationError(
37 [ # # ][ # # ]: 0 : "get_termfreq_est_using_stats() not meaningful for this PostingIterator");
[ # # ]
38 : : }
39 : :
40 : : Xapian::termcount
41 : 0 : PostList::get_wdf() const
42 : : {
43 [ # # ][ # # ]: 0 : throw Xapian::InvalidOperationError("get_wdf() not meaningful for this PostingIterator");
[ # # ]
44 : : }
45 : :
46 : : PositionList *
47 : 0 : PostList::read_position_list()
48 : : {
49 [ # # ][ # # ]: 0 : throw Xapian::UnimplementedError("OP_NEAR and OP_PHRASE only currently support leaf subqueries");
[ # # ]
50 : : }
51 : :
52 : : PositionList *
53 : 0 : PostList::open_position_list() const
54 : : {
55 [ # # ][ # # ]: 0 : throw Xapian::InvalidOperationError("open_position_list() not meaningful for this PostingIterator");
[ # # ]
56 : : }
57 : :
58 : : PostList *
59 : 7756 : PostList::check(Xapian::docid did, double w_min, bool &valid)
60 : : {
61 : 7756 : valid = true;
62 : 7756 : return skip_to(did, w_min);
63 : : }
64 : :
65 : : Xapian::termcount
66 : 0 : PostList::count_matching_subqs() const
67 : : {
68 : : Assert(false);
69 : 0 : return 0;
70 : : }
71 : :
72 : : void
73 : 0 : PostList::gather_position_lists(OrPositionList*)
74 : : {
75 : : Assert(false);
76 : 0 : }
|