QuartzAllTermsList Class Reference

class for alltermslists over several databases More...

#include <quartz_alltermslist.h>

Inheritance diagram for QuartzAllTermsList:

Inheritance graph
[legend]
Collaboration diagram for QuartzAllTermsList:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 QuartzAllTermsList (Xapian::Internal::RefCntPtr< const Xapian::Database::Internal > database_, AutoPtr< Bcursor > pl_cursor_, quartz_tablesize_t size_, const string &prefix_)
 Standard constructor for base class.
 ~QuartzAllTermsList ()
 Standard destructor for base class.
string get_termname () const
 Return the termname at the current position.
Xapian::doccount get_termfreq () const
 Return the term frequency for the term at the current position.
Xapian::termcount get_collection_freq () const
 Return the collection frequency for the term at the current position.
TermListskip_to (const string &tname)
TermListnext ()
 next() causes the AllTermsList to move to the next term in the list.
bool at_end () const
 Return true if the current position is past the last term in this list.

Private Member Functions

 QuartzAllTermsList (const QuartzAllTermsList &)
 Copying is not allowed.
void operator= (const QuartzAllTermsList &)
 Assignment is not allowed.
void get_stats () const

Private Attributes

Xapian::Internal::RefCntPtr<
const Xapian::Database::Internal
database
 Keep our database around.
AutoPtr< Bcursorpl_cursor
 A cursor pointing at the current term's postlist entry.
bool is_at_end
 Cached "at-end" value.
quartz_tablesize_t size
bool started
string current_term
 Cached termname.
string prefix
 The prefix to restrict the terms to.
bool have_stats
 Cached statistics.
Xapian::termcount termfreq
Xapian::termcount collection_freq

Detailed Description

class for alltermslists over several databases

Definition at line 33 of file quartz_alltermslist.h.


Constructor & Destructor Documentation

QuartzAllTermsList::QuartzAllTermsList ( const QuartzAllTermsList  )  [private]

Copying is not allowed.

QuartzAllTermsList::QuartzAllTermsList ( Xapian::Internal::RefCntPtr< const Xapian::Database::Internal database_,
AutoPtr< Bcursor pl_cursor_,
quartz_tablesize_t  size_,
const string &  prefix_ 
)

Standard constructor for base class.

Definition at line 30 of file quartz_alltermslist.cc.

References current_term, DEBUGCALL, have_stats, is_at_end, pack_string_preserving_sort(), pl_cursor, prefix, startswith(), and unpack_string_preserving_sort().

QuartzAllTermsList::~QuartzAllTermsList (  ) 

Standard destructor for base class.

Definition at line 69 of file quartz_alltermslist.cc.

References DEBUGCALL.


Member Function Documentation

void QuartzAllTermsList::operator= ( const QuartzAllTermsList  )  [private]

Assignment is not allowed.

void QuartzAllTermsList::get_stats (  )  const [private]

Definition at line 82 of file quartz_alltermslist.cc.

References collection_freq, have_stats, pl_cursor, QuartzPostList::read_number_of_entries(), and termfreq.

Referenced by get_collection_freq(), and get_termfreq().

string QuartzAllTermsList::get_termname (  )  const [virtual]

Return the termname at the current position.

Implements AllTermsList.

Definition at line 75 of file quartz_alltermslist.cc.

References Assert, current_term, DEBUGCALL, RETURN, and started.

Xapian::doccount QuartzAllTermsList::get_termfreq (  )  const [virtual]

Return the term frequency for the term at the current position.

Implements AllTermsList.

Definition at line 94 of file quartz_alltermslist.cc.

References Assert, DEBUGCALL, get_stats(), have_stats, is_at_end, RETURN, started, and termfreq.

Xapian::termcount QuartzAllTermsList::get_collection_freq (  )  const [virtual]

Return the collection frequency for the term at the current position.

Implements AllTermsList.

Definition at line 108 of file quartz_alltermslist.cc.

References Assert, collection_freq, DEBUGCALL, get_stats(), have_stats, is_at_end, RETURN, and started.

TermList * QuartzAllTermsList::skip_to ( const string &  tname  ) 

Definition at line 122 of file quartz_alltermslist.cc.

References current_term, DEBUGCALL, DEBUGLINE, have_stats, is_at_end, next(), pack_string_preserving_sort(), pl_cursor, prefix, RETURN, started, and startswith().

TermList * QuartzAllTermsList::next (  )  [virtual]

next() causes the AllTermsList to move to the next term in the list.

Implements AllTermsList.

Definition at line 152 of file quartz_alltermslist.cc.

References current_term, DEBUGCALL, have_stats, is_at_end, pl_cursor, prefix, RETURN, started, startswith(), and unpack_string_preserving_sort().

Referenced by skip_to().

bool QuartzAllTermsList::at_end (  )  const [virtual]

Return true if the current position is past the last term in this list.

Implements AllTermsList.

Definition at line 184 of file quartz_alltermslist.cc.

References DEBUGCALL, is_at_end, and RETURN.


Member Data Documentation

Xapian::Internal::RefCntPtr<const Xapian::Database::Internal> QuartzAllTermsList::database [private]

Keep our database around.

Definition at line 43 of file quartz_alltermslist.h.

AutoPtr<Bcursor> QuartzAllTermsList::pl_cursor [private]

A cursor pointing at the current term's postlist entry.

Definition at line 46 of file quartz_alltermslist.h.

Referenced by get_stats(), next(), QuartzAllTermsList(), and skip_to().

bool QuartzAllTermsList::is_at_end [private]

Cached "at-end" value.

Definition at line 49 of file quartz_alltermslist.h.

Referenced by at_end(), get_collection_freq(), get_termfreq(), next(), QuartzAllTermsList(), and skip_to().

quartz_tablesize_t QuartzAllTermsList::size [private]

Definition at line 51 of file quartz_alltermslist.h.

bool QuartzAllTermsList::started [private]

Definition at line 53 of file quartz_alltermslist.h.

Referenced by get_collection_freq(), get_termfreq(), get_termname(), next(), and skip_to().

string QuartzAllTermsList::current_term [private]

Cached termname.

Definition at line 56 of file quartz_alltermslist.h.

Referenced by get_termname(), next(), QuartzAllTermsList(), and skip_to().

string QuartzAllTermsList::prefix [private]

The prefix to restrict the terms to.

Definition at line 59 of file quartz_alltermslist.h.

Referenced by next(), QuartzAllTermsList(), and skip_to().

bool QuartzAllTermsList::have_stats [mutable, private]

Cached statistics.

Definition at line 62 of file quartz_alltermslist.h.

Referenced by get_collection_freq(), get_stats(), get_termfreq(), next(), QuartzAllTermsList(), and skip_to().

Xapian::termcount QuartzAllTermsList::termfreq [mutable, private]

Definition at line 63 of file quartz_alltermslist.h.

Referenced by get_stats(), and get_termfreq().

Xapian::termcount QuartzAllTermsList::collection_freq [mutable, private]

Definition at line 64 of file quartz_alltermslist.h.

Referenced by get_collection_freq(), and get_stats().


The documentation for this class was generated from the following files:
Documentation for Xapian (version 1.0.10).
Generated on 24 Dec 2008 by Doxygen 1.5.2.