libdballe 9.6
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | Protected Member Functions | List of all members
dballe::db::v7::cursor::Base< Impl > Struct Template Reference

Structure used to build and execute a query, and to iterate through the results. More...

#include <cursor.h>

Inheritance diagram for dballe::db::v7::cursor::Base< Impl >:
dballe::db::v7::cursor::LevTrBase< Data > dballe::db::v7::cursor::LevTrBase< Summary > dballe::db::v7::cursor::LevTrBase< Impl > dballe::db::v7::cursor::Data dballe::db::v7::cursor::Summary

Public Types

typedef ImplTraits< Impl >::Row Row
 
typedef ImplTraits< Impl >::Interface Interface
 

Public Member Functions

 Base (std::shared_ptr< v7::Transaction > tr)
 
int remaining () const override
 
bool has_value () const
 
bool next () override
 
void discard () override
 
dballe::DBStation get_station () const override
 
unsigned test_iterate (FILE *dump=0) override
 Iterate the cursor until the end, returning the number of items.
 
const Row & row () const
 

Static Public Member Functions

static std::shared_ptr< Impl > downcast (std::shared_ptr< Interface > c)
 

Public Attributes

std::shared_ptr< v7::Transactiontr
 Database to operate on.
 
std::deque< Row > results
 Storage for the raw database results.
 
bool at_start = true
 True if we are at the start of the iteration.
 

Protected Member Functions

int get_priority () const
 

Detailed Description

template<typename Impl>
struct dballe::db::v7::cursor::Base< Impl >

Structure used to build and execute a query, and to iterate through the results.

Member Function Documentation

◆ test_iterate()

template<typename Impl >
unsigned dballe::db::v7::cursor::Base< Impl >::test_iterate ( FILE *  dump = 0)
override

Iterate the cursor until the end, returning the number of items.

If dump is a FILE pointer, also dump the cursor values to it


The documentation for this struct was generated from the following file: