22 #ifndef XAPIAN_INCLUDED_ESET_H
23 #define XAPIAN_INCLUDED_ESET_H
25 #if !defined XAPIAN_IN_XAPIAN_H && !defined XAPIAN_LIB_BUILD
26 # error Never use <xapian/eset.h> directly; include <xapian.h> instead.
64 #ifdef XAPIAN_MOVE_SEMANTICS
85 bool empty()
const {
return size() == 0; }
110 std::string get_description()
const;
164 : eset(eset_), off_from_end(off_from_end_) { }
266 double get_weight()
const;
269 std::string get_description()
const;
273 XAPIAN_NOTHROW(
operator==(
const ESetIterator &a,
const ESetIterator &b));
279 return a.off_from_end == b.off_from_end;
283 XAPIAN_NOTHROW(
operator!=(
const ESetIterator &a,
const ESetIterator &b));
293 XAPIAN_NOTHROW(
operator<(
const ESetIterator &a,
const ESetIterator &b));
299 return a.off_from_end > b.off_from_end;
303 XAPIAN_NOTHROW(
operator>(
const ESetIterator &a,
const ESetIterator &b));
313 XAPIAN_NOTHROW(
operator>=(
const ESetIterator &a,
const ESetIterator &b));
323 XAPIAN_NOTHROW(
operator<=(
const ESetIterator &a,
const ESetIterator &b));
Compiler attribute macros.
Iterator over a Xapian::ESet.
ESetIterator operator-(difference_type n) const
Return the iterator decremented by n positions.
ESetIterator & operator++()
Advance the iterator to the next position.
Xapian::termcount_diff difference_type
ESetIterator operator--(int)
Move the iterator to the previous position (postfix version).
Xapian::ESet::size_type off_from_end
ESetIterator & operator-=(difference_type n)
Move the iterator back by n positions.
difference_type operator-(const ESetIterator &o) const
Return the number of positions between o and this iterator.
ESetIterator operator+(difference_type n) const
Return the iterator incremented by n positions.
ESetIterator()
Create an unpositioned ESetIterator.
ESetIterator operator++(int)
Advance the iterator to the next position (postfix version).
ESetIterator(const Xapian::ESet &eset_, Xapian::doccount off_from_end_)
std::random_access_iterator_tag iterator_category
ESetIterator & operator--()
Move the iterator to the previous position.
ESetIterator & operator+=(difference_type n)
Move the iterator forwards by n positions.
Class which actually implements Xapian::ESet.
Class representing a list of search results.
Xapian::termcount size_type
const value_type & const_reference
Xapian::ESetIterator const_iterator
const value_type * const_pointer
ESetIterator back() const
Return iterator pointing to the last object in this ESet.
Xapian::ESetIterator value_type
ESetIterator operator[](Xapian::doccount i) const
Return iterator pointing to the i-th object in this ESet.
Xapian::ESetIterator iterator
Xapian::doccount max_size() const
ESetIterator end() const
Return iterator pointing to just after the last item in this ESet.
Xapian::Internal::intrusive_ptr< Internal > internal
Xapian::termcount_diff difference_type
friend class ESetIterator
Xapian::doccount size() const
Return number of items in this ESet object.
void swap(ESet &o)
Efficiently swap this ESet object with another.
bool empty() const
Return true if this ESet object is empty.
ESetIterator begin() const
Return iterator pointing to the first item in this ESet.
A smart pointer that uses intrusive reference counting.
The Xapian namespace contains public interfaces for the Xapian library.
bool operator>=(const ESetIterator &a, const ESetIterator &b)
Inequality test for ESetIterator objects.
XAPIAN_TERMCOUNT_BASE_TYPE termcount_diff
A signed difference between two counts of terms.
unsigned XAPIAN_TERMCOUNT_BASE_TYPE termcount
A counts of terms.
bool operator<=(const ESetIterator &a, const ESetIterator &b)
Inequality test for ESetIterator objects.
bool operator>(const ESetIterator &a, const ESetIterator &b)
Inequality test for ESetIterator objects.
unsigned XAPIAN_DOCID_BASE_TYPE doccount
A count of documents.
bool operator==(const ESetIterator &a, const ESetIterator &b)
Equality test for ESetIterator objects.
bool operator!=(const ESetIterator &a, const ESetIterator &b)
Inequality test for ESetIterator objects.
ESetIterator operator+(ESetIterator::difference_type n, const ESetIterator &it)
Return ESetIterator it incremented by n positions.
bool operator<(const ESetIterator &a, const ESetIterator &b)
Inequality test for ESetIterator objects.
const Query operator*(double factor, const Query &q)
Scale a Xapian::Query object using OP_SCALE_WEIGHT.
Define XAPIAN_VISIBILITY_* macros.
#define XAPIAN_VISIBILITY_DEFAULT