21 #ifndef XAPIAN_INCLUDED_MSETINTERNAL_H
22 #define XAPIAN_INCLUDED_MSETINTERNAL_H
35 #include <string_view>
36 #include <unordered_map>
47 friend class ::Matcher;
62 std::unique_ptr<Xapian::Weight::Internal>
stats;
99 std::vector<Result>&& items_,
100 double percent_scale_factor_)
101 :
items(std::move(items_)),
137 std::string
snippet(std::string_view text,
141 std::string_view hi_start,
142 std::string_view hi_end,
143 std::string_view omit)
const;
Class representing a document.
Base class for objects managed by intrusive_ptr.
A smart pointer that uses intrusive reference counting.
Iterator over a Xapian::MSet.
Xapian::doccount uncollapsed_upper_bound
std::string serialise() const
Serialise this object.
void operator=(const Internal &)=delete
Don't allow assignment.
Xapian::Weight::Internal * get_stats() const
void set_first(Xapian::doccount first_)
int convert_to_percent(double weight) const
Xapian::Internal::intrusive_ptr< const Enquire::Internal > enquire
std::unordered_map< std::string, double > snippet_bg_relevance
Relevance weights for non-query terms for generating snippets.
std::string get_description() const
Return a string describing this object.
std::unique_ptr< Xapian::Weight::Internal > stats
For looking up query term frequencies and weights.
std::vector< Result > items
The items in the MSet.
Xapian::doccount uncollapsed_lower_bound
Internal(const Internal &)=delete
Don't allow copying.
Xapian::doccount matches_estimated
void unshard_docids(Xapian::doccount shard, Xapian::doccount n_shards)
void unserialise(const char *p, const char *p_end)
Unserialise a serialised Xapian::MSet::Internal object.
Xapian::Document get_document(Xapian::doccount index) const
void merge_stats(const Internal *o, bool collapsing)
void fetch(Xapian::doccount first, Xapian::doccount last) const
double get_percent_scale_factor() const
void set_item_weight(Xapian::doccount i, double weight)
Xapian::doccount matches_lower_bound
std::string snippet(std::string_view text, size_t length, const Xapian::Stem &stemmer, unsigned flags, std::string_view hi_start, std::string_view hi_end, std::string_view omit) const
double percent_scale_factor
Scale factor to convert weights to percentages.
Internal(Xapian::doccount first_, Xapian::doccount matches_upper_bound_, Xapian::doccount matches_lower_bound_, Xapian::doccount matches_estimated_, Xapian::doccount uncollapsed_upper_bound_, Xapian::doccount uncollapsed_lower_bound_, Xapian::doccount uncollapsed_estimated_, double max_possible_, double max_attained_, std::vector< Result > &&items_, double percent_scale_factor_)
void set_stats(Xapian::Weight::Internal *stats_)
Xapian::doccount matches_upper_bound
void set_enquire(const Xapian::Enquire::Internal *enquire_)
Xapian::doccount uncollapsed_estimated
Class representing a list of search results.
Class representing a stemming algorithm.
Class to hold statistics for a given collection.
Xapian::Enquire internals.
Class representing a list of search results.
The Xapian namespace contains public interfaces for the Xapian library.
unsigned XAPIAN_DOCID_BASE_TYPE doccount
A count of documents.
functions to convert classes to strings and back
static Xapian::Stem stemmer
Xapian::Weight::Internal class, holding database and term statistics.