#include <inmemory_positionlist.h>
Inheritance diagram for InMemoryPositionList:


Public Member Functions | |
| InMemoryPositionList () | |
| Default constructor. | |
| InMemoryPositionList (const OmDocumentTerm::term_positions &positions_) | |
| Construct, fill list with data, and move the position to the start. | |
| ~InMemoryPositionList () | |
| Destructor. | |
| void | set_data (const OmDocumentTerm::term_positions &positions_) |
| Fill list with data, and move the position to the start. | |
| Xapian::termcount | get_size () const |
| Gets size of position list. | |
| Xapian::termpos | get_position () const |
| Gets current position. | |
| void | next () |
| Move to the next item in the list. | |
| void | skip_to (Xapian::termpos termpos) |
| Move to the next item in the list. | |
| bool | at_end () const |
| True if we're off the end of the list. | |
Private Member Functions | |
| InMemoryPositionList (const InMemoryPositionList &) | |
| Copying is not allowed. | |
| void | operator= (const InMemoryPositionList &) |
| Assignment is not allowed. | |
Private Attributes | |
| vector< Xapian::termpos > | positions |
| The list of positions. | |
| vector< Xapian::termpos >::const_iterator | mypos |
| Position of iteration through positions. | |
| bool | iterating_in_progress |
| True if we have started iterating. | |
Definition at line 38 of file inmemory_positionlist.h.
| InMemoryPositionList::InMemoryPositionList | ( | const InMemoryPositionList & | ) | [private] |
Copying is not allowed.
| InMemoryPositionList::InMemoryPositionList | ( | ) | [inline] |
| InMemoryPositionList::InMemoryPositionList | ( | const OmDocumentTerm::term_positions & | positions_ | ) |
Construct, fill list with data, and move the position to the start.
Definition at line 28 of file inmemory_positionlist.cc.
| InMemoryPositionList::~InMemoryPositionList | ( | ) | [inline] |
| void InMemoryPositionList::operator= | ( | const InMemoryPositionList & | ) | [private] |
Assignment is not allowed.
| void InMemoryPositionList::set_data | ( | const OmDocumentTerm::term_positions & | positions_ | ) |
Fill list with data, and move the position to the start.
Definition at line 35 of file inmemory_positionlist.cc.
References iterating_in_progress, mypos, and positions.
Referenced by InMemoryPostList::read_position_list().
| Xapian::termcount InMemoryPositionList::get_size | ( | ) | const [virtual] |
Gets size of position list.
Implements Xapian::PositionIterator::Internal.
Definition at line 43 of file inmemory_positionlist.cc.
References positions.
| Xapian::termpos InMemoryPositionList::get_position | ( | ) | const [virtual] |
Gets current position.
Implements Xapian::PositionIterator::Internal.
Definition at line 49 of file inmemory_positionlist.cc.
References Assert, at_end(), iterating_in_progress, and mypos.
| void InMemoryPositionList::next | ( | ) | [virtual] |
Move to the next item in the list.
Either next() or skip_to() must be called before any other methods.
Implements Xapian::PositionIterator::Internal.
Definition at line 57 of file inmemory_positionlist.cc.
References Assert, at_end(), iterating_in_progress, and mypos.
| void InMemoryPositionList::skip_to | ( | Xapian::termpos | termpos | ) | [virtual] |
Move to the next item in the list.
Either next() or skip_to() must be called before any other methods.
Implements Xapian::PositionIterator::Internal.
Definition at line 68 of file inmemory_positionlist.cc.
References at_end(), iterating_in_progress, and mypos.
| bool InMemoryPositionList::at_end | ( | ) | const [virtual] |
True if we're off the end of the list.
Implements Xapian::PositionIterator::Internal.
Definition at line 75 of file inmemory_positionlist.cc.
References mypos, and positions.
Referenced by get_position(), next(), and skip_to().
vector<Xapian::termpos> InMemoryPositionList::positions [private] |
The list of positions.
Definition at line 42 of file inmemory_positionlist.h.
Referenced by at_end(), get_size(), and set_data().
vector<Xapian::termpos>::const_iterator InMemoryPositionList::mypos [private] |
Position of iteration through positions.
Definition at line 45 of file inmemory_positionlist.h.
Referenced by at_end(), get_position(), next(), set_data(), and skip_to().
bool InMemoryPositionList::iterating_in_progress [private] |
True if we have started iterating.
Definition at line 48 of file inmemory_positionlist.h.
Referenced by get_position(), next(), set_data(), and skip_to().