xapian-core  1.4.21
multi_alltermslist.h
Go to the documentation of this file.
1 
4 /* Copyright (C) 2007,2008,2011 Olly Betts
5  *
6  * This program is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; either version 2 of the License, or
9  * (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 #ifndef XAPIAN_INCLUDED_MULTI_ALLTERMSLIST_H
22 #define XAPIAN_INCLUDED_MULTI_ALLTERMSLIST_H
23 
24 #include "backends/alltermslist.h"
25 
26 #include "backends/database.h"
27 
28 #include <string>
29 #include <vector>
30 
34  void operator=(const MultiAllTermsList &);
35 
38 
40  std::string current_term;
41 
43  std::vector<TermList *> termlists;
44 
45  public:
48  const std::string & prefix);
49 
52 
54  std::string get_termname() const;
55 
58 
60  TermList *next();
61 
67  TermList *skip_to(const std::string &term);
68 
70  bool at_end() const;
71 };
72 
73 #endif // XAPIAN_INCLUDED_MULTI_ALLTERMSLIST_H
~MultiAllTermsList()
Destructor.
Abstract base class for termlists.
Definition: termlist.h:39
void operator=(const MultiAllTermsList &)
Don&#39;t allow assignment.
Class for merging AllTermsList objects from subdatabases.
Xapian::doccount get_termfreq() const
Return the term frequency for the term at the current position.
std::string current_term
Current termname (or empty if we haven&#39;t started yet).
bool at_end() const
Return true if the current position is past the last term in this list.
Abstract base class for iterating all terms in a database.
unsigned XAPIAN_DOCID_BASE_TYPE doccount
A count of documents.
Definition: types.h:38
std::string get_termname() const
Return the termname at the current position.
Abstract base class for iterating all terms in a database.
Definition: alltermslist.h:27
TermList * next()
Advance the current position to the next term in the termlist.
std::vector< TermList * > termlists
Vector of sub-termlists which we use as a heap.
TermList * skip_to(const std::string &term)
Skip forward to the specified term.
MultiAllTermsList(const MultiAllTermsList &)
Don&#39;t allow copying.