| Apache Ignite C++

Public Member Functions | List of all members
ignite::thin::cache::query::QueryCursor< K, V > Class Template Reference

Query cursor class template. More...

`#include <query_cursor.h>`

## Public Member Functions
| QueryCursor ()
| Default constructor.
| QueryCursor (const impl::thin::cache::query::QueryCursorProxy &impl)
| Constructor. More...
bool | HasNext () const
| Check whether next entry exists. More...
CacheEntry< K, V > | GetNext ()
| Get next entry. More...
void | GetAll (std::vector< CacheEntry< K, V > > &res)
| Get all entries. More...
template<typename OutIter >
void | GetAll (OutIter iter)
| Get all entries. More...

## Detailed Description

### template<typename K, typename V>
class ignite::thin::cache::query::QueryCursor< K, V >

Query cursor class template.

Both key and value types should be default-constructable, copy-constructable and assignable. Also BinaryType class template should be specialized for both types.

This class is implemented as a reference to an implementation so copying of this class instance will only create another reference to the same underlying object. Underlying object will be released automatically once all the instances are destructed.

## Constructor & Destructor Documentation

## ◆ QueryCursor()

template<typename K , typename V >

ignite::thin::cache::query::QueryCursor< K, V >::QueryCursor | ( | const impl::thin::cache::query::QueryCursorProxy & | impl | ) |
| inline explicit

Constructor.

Parameters

  impl | Implementation.

## Member Function Documentation

## ◆ GetAll() [1/2]

template<typename K , typename V >
template<typename OutIter >

void ignite::thin::cache::query::QueryCursor< K, V >::GetAll | ( | OutIter | iter | ) |
| inline

Get all entries.

Parameters

  iter | Output iterator.

Exceptions

  IgniteError | class instance in case of failure.

## ◆ GetAll() [2/2]

template<typename K , typename V >

void ignite::thin::cache::query::QueryCursor< K, V >::GetAll | ( | std::vector< CacheEntry< K, V > > & | res | ) |
| inline

Get all entries.

Parameters

  res | Vector where query entries will be stored.

Exceptions

  IgniteError | class instance in case of failure.

## ◆ GetNext()

template<typename K , typename V >

CacheEntry<K, V> ignite::thin::cache::query::QueryCursor< K, V >::GetNext | ( |  | ) |
| inline

Get next entry.

Returns
  Next entry.

Exceptions

  IgniteError | class instance in case of failure.

## ◆ HasNext()

template<typename K , typename V >

bool ignite::thin::cache::query::QueryCursor< K, V >::HasNext | ( |  | ) | const
| inline

Check whether next entry exists.

Returns
  True if next entry exists.

Exceptions

  IgniteError | class instance in case of failure.

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

- thin-client/include/ignite/thin/cache/query/query_cursor.h