#include <branchpostlist.h>
Inheritance diagram for BranchPostList:
Public Member Functions | |
BranchPostList (PostList *l_, PostList *r_, MultiMatch *matcher_) | |
virtual | ~BranchPostList () |
virtual Xapian::termcount | get_wdf () const |
get_wdf() for branch postlists returns the sum of the wdfs of the sub postlists. | |
Protected Member Functions | |
void | handle_prune (PostList *&kid, PostList *ret) |
Utility method, to call recalc_maxweight() and do the pruning if a next() or skip_to() returns non-NULL result. | |
Protected Attributes | |
PostList * | l |
Left sub-postlist. | |
PostList * | r |
Right sub-postlist. | |
MultiMatch * | matcher |
The object which is using this postlist to perform a match. | |
Private Member Functions | |
BranchPostList (const BranchPostList &) | |
BranchPostList & | operator= (const BranchPostList &) |
These postlists form a tree which is used to perform a sum over all the terms in the query for each document, in order to calculate the score for that document.
Definition at line 37 of file branchpostlist.h.
BranchPostList::BranchPostList | ( | const BranchPostList & | ) | [private] |
BranchPostList::BranchPostList | ( | PostList * | l_, | |
PostList * | r_, | |||
MultiMatch * | matcher_ | |||
) | [inline] |
Definition at line 71 of file branchpostlist.h.
BranchPostList::~BranchPostList | ( | ) | [virtual] |
BranchPostList& BranchPostList::operator= | ( | const BranchPostList & | ) | [private] |
Utility method, to call recalc_maxweight() and do the pruning if a next() or skip_to() returns non-NULL result.
Definition at line 60 of file branchpostlist.h.
References matcher, and MultiMatch::recalc_maxweight().
Referenced by AndNotPostList::advance_to_next_match(), AndPostList::process_next_or_skip_to(), and AndMaybePostList::process_next_or_skip_to().
Xapian::termcount BranchPostList::get_wdf | ( | ) | const [virtual] |
get_wdf() for branch postlists returns the sum of the wdfs of the sub postlists.
The wdf isn't really meaningful in many situations, but if the lists are being combined as a synonym we want the sum of the wdfs, so we do that in general.
Reimplemented from Xapian::PostingIterator::Internal.
Definition at line 34 of file branchpostlist.cc.
References Xapian::PostingIterator::Internal::get_wdf(), l, and r.
PostList* BranchPostList::l [protected] |
Left sub-postlist.
Definition at line 45 of file branchpostlist.h.
Referenced by XorPostList::advance_to_next_match(), AndNotPostList::advance_to_next_match(), AndMaybePostList::AndMaybePostList(), AndPostList::AndPostList(), OrPostList::at_end(), XorPostList::get_description(), OrPostList::get_description(), AndPostList::get_description(), AndNotPostList::get_description(), AndMaybePostList::get_description(), XorPostList::get_doclength(), OrPostList::get_doclength(), AndPostList::get_doclength(), AndNotPostList::get_doclength(), AndMaybePostList::get_doclength(), AndNotPostList::get_maxweight(), XorPostList::get_termfreq_est(), OrPostList::get_termfreq_est(), AndPostList::get_termfreq_est(), AndNotPostList::get_termfreq_est(), AndMaybePostList::get_termfreq_est(), XorPostList::get_termfreq_max(), OrPostList::get_termfreq_max(), AndPostList::get_termfreq_max(), AndNotPostList::get_termfreq_max(), AndMaybePostList::get_termfreq_max(), XorPostList::get_termfreq_min(), OrPostList::get_termfreq_min(), AndPostList::get_termfreq_min(), AndNotPostList::get_termfreq_min(), AndMaybePostList::get_termfreq_min(), get_wdf(), XorPostList::get_weight(), OrPostList::get_weight(), AndPostList::get_weight(), AndNotPostList::get_weight(), AndMaybePostList::get_weight(), XorPostList::next(), OrPostList::next(), AndNotPostList::next(), AndMaybePostList::next(), AndPostList::process_next_or_skip_to(), AndMaybePostList::process_next_or_skip_to(), XorPostList::recalc_maxweight(), OrPostList::recalc_maxweight(), AndPostList::recalc_maxweight(), AndNotPostList::recalc_maxweight(), AndMaybePostList::recalc_maxweight(), XorPostList::skip_to(), OrPostList::skip_to(), AndNotPostList::skip_to(), AndMaybePostList::skip_to(), and ~BranchPostList().
PostList* BranchPostList::r [protected] |
Right sub-postlist.
Definition at line 48 of file branchpostlist.h.
Referenced by XorPostList::advance_to_next_match(), AndNotPostList::advance_to_next_match(), AndMaybePostList::AndMaybePostList(), AndPostList::AndPostList(), OrPostList::at_end(), XorPostList::get_description(), OrPostList::get_description(), AndPostList::get_description(), AndNotPostList::get_description(), AndMaybePostList::get_description(), XorPostList::get_doclength(), OrPostList::get_doclength(), AndPostList::get_doclength(), AndMaybePostList::get_doclength(), XorPostList::get_termfreq_est(), OrPostList::get_termfreq_est(), AndPostList::get_termfreq_est(), AndNotPostList::get_termfreq_est(), XorPostList::get_termfreq_max(), OrPostList::get_termfreq_max(), AndPostList::get_termfreq_max(), XorPostList::get_termfreq_min(), OrPostList::get_termfreq_min(), AndPostList::get_termfreq_min(), AndNotPostList::get_termfreq_min(), get_wdf(), XorPostList::get_weight(), OrPostList::get_weight(), AndPostList::get_weight(), AndMaybePostList::get_weight(), XorPostList::next(), OrPostList::next(), AndPostList::next(), AndMaybePostList::next(), AndPostList::process_next_or_skip_to(), AndMaybePostList::process_next_or_skip_to(), XorPostList::recalc_maxweight(), OrPostList::recalc_maxweight(), AndPostList::recalc_maxweight(), AndMaybePostList::recalc_maxweight(), XorPostList::skip_to(), OrPostList::skip_to(), AndPostList::skip_to(), AndMaybePostList::skip_to(), and ~BranchPostList().
MultiMatch* BranchPostList::matcher [protected] |
The object which is using this postlist to perform a match.
This object needs to be notified when the tree changes such that the maximum weights need to be recalculated.
Definition at line 55 of file branchpostlist.h.
Referenced by XorPostList::advance_to_next_match(), AndNotPostList::advance_to_next_match(), handle_prune(), XorPostList::next(), OrPostList::next(), AndMaybePostList::next(), AndPostList::process_next_or_skip_to(), AndMaybePostList::process_next_or_skip_to(), XorPostList::skip_to(), OrPostList::skip_to(), and AndMaybePostList::skip_to().