FlintMetadataTermList Class Reference

#include <flint_metadata.h>

Inheritance diagram for FlintMetadataTermList:

Inheritance graph
[legend]
Collaboration diagram for FlintMetadataTermList:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 FlintMetadataTermList (Xapian::Internal::RefCntPtr< const Xapian::Database::Internal > database_, FlintCursor *cursor_, const std::string &prefix_)
 ~FlintMetadataTermList ()
std::string get_termname () const
 Returns the current termname.
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.
TermListnext ()
 Advance to the next term in the list.
TermListskip_to (const std::string &tname)
 Advance to the first term which is >= tname.
bool at_end () const
 True if we're off the end of the list.

Private Member Functions

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

Private Attributes

Xapian::Internal::RefCntPtr<
const Xapian::Database::Internal
database
 Keep a reference to our database to stop it being deleted.
FlintCursorcursor
 A cursor which runs through the postlist table reading metadata keys.
std::string prefix
 The prefix that all returned keys must have.

Detailed Description

Definition at line 38 of file flint_metadata.h.


Constructor & Destructor Documentation

FlintMetadataTermList::FlintMetadataTermList ( const FlintMetadataTermList  )  [private]

Copying is not allowed.

FlintMetadataTermList::FlintMetadataTermList ( Xapian::Internal::RefCntPtr< const Xapian::Database::Internal database_,
FlintCursor cursor_,
const std::string &  prefix_ 
)

FlintMetadataTermList::~FlintMetadataTermList (  ) 

Definition at line 43 of file flint_metadata.cc.

References cursor, and DEBUGCALL.


Member Function Documentation

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

Assignment is not allowed.

string FlintMetadataTermList::get_termname (  )  const [virtual]

Returns the current termname.

Either next() or skip_to() must have been called before this method can be called.

Implements AllTermsList.

Definition at line 50 of file flint_metadata.cc.

References Assert, at_end(), FlintCursor::current_key, cursor, DEBUGCALL, prefix, RETURN, and startswith().

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

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

Not meaningful for a FlintMetadataTermList.

Implements AllTermsList.

Definition at line 60 of file flint_metadata.cc.

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

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

Not meaningful for a FlintMetadataTermList.

Implements AllTermsList.

Definition at line 66 of file flint_metadata.cc.

TermList * FlintMetadataTermList::next (  )  [virtual]

Advance to the next term in the list.

Implements AllTermsList.

Definition at line 72 of file flint_metadata.cc.

References FlintCursor::after_end(), Assert, at_end(), FlintCursor::current_key, cursor, DEBUGCALL, FlintCursor::next(), prefix, RETURN, startswith(), and FlintCursor::to_end().

TermList* FlintMetadataTermList::skip_to ( const std::string &  tname  )  [virtual]

Advance to the first term which is >= tname.

Implements AllTermsList.

bool FlintMetadataTermList::at_end (  )  const [virtual]

True if we're off the end of the list.

Implements AllTermsList.

Definition at line 104 of file flint_metadata.cc.

References FlintCursor::after_end(), cursor, DEBUGCALL, and RETURN.

Referenced by get_termname(), and next().


Member Data Documentation

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

Keep a reference to our database to stop it being deleted.

Definition at line 46 of file flint_metadata.h.

FlintCursor* FlintMetadataTermList::cursor [private]

A cursor which runs through the postlist table reading metadata keys.

Definition at line 50 of file flint_metadata.h.

Referenced by at_end(), get_termname(), next(), and ~FlintMetadataTermList().

std::string FlintMetadataTermList::prefix [private]

The prefix that all returned keys must have.

Definition at line 54 of file flint_metadata.h.

Referenced by get_termname(), and next().


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.