Class ConstReverseResultIterator

Synopsis

#include <orm_lib/inc/drogon/orm/ResultIterator.h>

class ConstReverseResultIterator : private ConstResultIterator

Description

No description yet.

Inheritance

Ancestors: ConstResultIterator

Methods

ConstReverseResultIterator
base
operator!=
operator*
operator++
operator+=
operator--
operator-=
operator<
operator<=
operator==
operator>
operator>=

Source

Lines 109-182 in orm_lib/inc/drogon/orm/ResultIterator.h. Line 110 in orm_lib/inc/drogon/orm/ResultIterator.h.

class ConstReverseResultIterator : private ConstResultIterator
{
  public:
    using super = ConstResultIterator;
    using iterator_type = ConstResultIterator;
    using iterator_type::difference_type;
    using iterator_type::iterator_category;
    using iterator_type::pointer;
    using iterator_type::reference;
    // using iterator_type::value_type;

    ConstReverseResultIterator(const ConstReverseResultIterator &rhs)
        : ConstResultIterator(rhs)
    {
    }
    explicit ConstReverseResultIterator(const ConstResultIterator &rhs)
        : ConstResultIterator(rhs)
    {
        super::operator--();
    }

    ConstResultIterator base() const noexcept;

    using iterator_type::operator->;
    using iterator_type::operator*;

    ConstReverseResultIterator operator++(int);
    ConstReverseResultIterator &operator++()
    {
        iterator_type::operator--();
        return *this;
    }
    ConstReverseResultIterator operator--(int);
    ConstReverseResultIterator &operator--()
    {
        iterator_type::operator++();
        return *this;
    }
    ConstReverseResultIterator &operator+=(difference_type i)
    {
        iterator_type::operator-=(i);
        return *this;
    }
    ConstReverseResultIterator &operator-=(difference_type i)
    {
        iterator_type::operator+=(i);
        return *this;
    }

    bool operator==(const ConstReverseResultIterator &other) const
    {
        return index_ == other.index_;
    }
    bool operator!=(const ConstReverseResultIterator &other) const
    {
        return index_ != other.index_;
    }
    bool operator>(const ConstReverseResultIterator &other) const
    {
        return index_ < other.index_;
    }
    bool operator<(const ConstReverseResultIterator &other) const
    {
        return index_ > other.index_;
    }
    bool operator>=(const ConstReverseResultIterator &other) const
    {
        return index_ <= other.index_;
    }
    bool operator<=(const ConstReverseResultIterator &other) const
    {
        return index_ >= other.index_;
    }
};





Add Discussion as Guest

Log in to DocsForge