26 #ifndef XAPIAN_INCLUDED_ENQUIRE_H
27 #define XAPIAN_INCLUDED_ENQUIRE_H
29 #if !defined XAPIAN_IN_XAPIAN_H && !defined XAPIAN_LIB_BUILD
30 # error Never use <xapian/enquire.h> directly; include <xapian.h> instead.
72 void operator=(
const RSet &rset);
74 #ifdef XAPIAN_MOVE_SEMANTICS
113 std::string get_description()
const;
158 void operator=(
const Enquire & other);
160 #ifdef XAPIAN_MOVE_SEMANTICS
259 void clear_matchspies();
267 void set_weighting_scheme(
const Weight &weight_);
285 void set_expansion_scheme(
const std::string &eweightname_,
286 double expand_k_ = 1.0)
const;
360 void set_docid_order(docid_order order);
380 void set_cutoff(
int percent_cutoff,
double weight_cutoff = 0);
386 void set_sort_by_relevance();
507 void set_time_limit(
double time_limit);
547 const RSet * omrset = 0,
583 return get_mset(first, maxitems, 0, omrset, mdecider);
595 static const int INCLUDE_QUERY_TERMS = 1;
605 static const int USE_EXACT_TERMFREQ = 2;
632 double min_wt = 0.0)
const;
649 return get_eset(maxitems, omrset, 0, edecider);
681 double min_wt = 0.0)
const) {
682 set_expansion_scheme(
"trad", k);
683 return get_eset(maxitems, rset, flags, edecider, min_wt);
751 std::string get_description()
const;
static Xapian::Query query(Xapian::Query::op op, const string &t1=string(), const string &t2=string(), const string &t3=string(), const string &t4=string(), const string &t5=string(), const string &t6=string(), const string &t7=string(), const string &t8=string(), const string &t9=string(), const string &t10=string())
Compiler attribute macros.
This class is used to access a database, or a group of databases.
A handle representing a document in a Xapian database.
Class representing a list of search results.
Internals of enquire system.
This class provides an interface to the information retrieval system for the purpose of searching.
MSet get_mset(Xapian::doccount first, Xapian::doccount maxitems, const RSet *omrset, const MatchDecider *mdecider=0) const
Get (a portion of) the match set for the current query.
TermIterator get_matching_terms_end(const MSetIterator &) const
End iterator corresponding to get_matching_terms_begin()
ESet get_eset(Xapian::termcount maxitems, const RSet &omrset, const Xapian::ExpandDecider *edecider) const
Get the expand set for the given rset.
TermIterator get_matching_terms_end(Xapian::docid) const
End iterator corresponding to get_matching_terms_begin()
Decide if a Xapian::Error exception should be ignored.
Virtual base class for expand decider functor.
A smart pointer that uses intrusive reference counting.
Virtual base class for key making functors.
Iterator over a Xapian::MSet.
Class representing a list of search results.
Base class for matcher decision functor.
void operator=(const MatchDecider &)
Don't allow assignment.
virtual bool operator()(const Xapian::Document &doc) const =0
Decide whether we want this document to be in the MSet.
MatchDecider()
Default constructor.
MatchDecider(const MatchDecider &)
Don't allow copying.
Abstract base class for match spies.
Class representing a query.
void remove_document(const Xapian::MSetIterator &i)
Remove a document from the relevance set.
bool contains(const Xapian::MSetIterator &i) const
Test if a given document in the relevance set.
void add_document(const Xapian::MSetIterator &i)
Add a document to the relevance set.
Class for iterating over a list of terms.
Abstract base class for weighting schemes.
Define XAPIAN_DEPRECATED() and related macros.
#define XAPIAN_DEPRECATED_EX(D)
Class representing a list of query expansion terms.
Class representing a list of search results.
The Xapian namespace contains public interfaces for the Xapian library.
unsigned XAPIAN_TERMCOUNT_BASE_TYPE termcount
A counts of terms.
unsigned valueno
The number for a value slot in a document.
unsigned XAPIAN_DOCID_BASE_TYPE doccount
A count of documents.
unsigned XAPIAN_DOCID_BASE_TYPE docid
A unique identifier for a document.
#define XAPIAN_DEPRECATED(X)
bool contains(const std::string &s, char substring)
Class for iterating over a list of terms.
Define XAPIAN_VISIBILITY_* macros.
#define XAPIAN_VISIBILITY_DEFAULT