ThinSQLite++
A thin, safe and convenient modern C++ wrapper for SQLite API.
|
A forward iterator for statement results. More...
Public Types | |
using | value_type = row |
using | size_type = int |
using | difference_type = int |
using | reference = row |
using | pointer = void |
using | iterator_category = std::forward_iterator_tag |
Public Member Functions | |
row_iterator () noexcept | |
Create an empty iterator. | |
row_iterator (statement *owner) | |
Create an instance referring to a given statement. | |
row_iterator (std::unique_ptr< statement > &owner) | |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. | |
row | operator* () const noexcept |
const row * | operator-> () const noexcept |
row_iterator & | operator++ () |
row_iterator | operator++ (int) |
Friends | |
bool | operator== (const row_iterator &lhs, const row_iterator &rhs) noexcept |
bool | operator!= (const row_iterator &lhs, const row_iterator &rhs) noexcept |
A forward iterator for statement results.
This class stores the statement by reference. Thus statement must remain valid for the lifetime duration of this class.
#include <thinsqlitepp/statement.hpp>
|
inlinenoexcept |
Create an empty iterator.
Such iterator is usable as an end of range sentinel
|
inline |
Create an instance referring to a given statement.
Note that the iterator mutates the statement while iterating, hence the argument must be non-const.