| Apache Ignite C++

Public Member Functions | List of all members
ignite::binary::BinaryCollectionReader< T > Class Template Reference

Binary collection reader. More...

`#include <binary_containers.h>`

## Public Member Functions
| BinaryCollectionReader (impl::binary::BinaryReaderImpl *impl, int32_t id, const CollectionType::Type type, int32_t size)
| Constructor. More...
bool | HasNext ()
| Check whether next element is available for read. More...
T | GetNext ()
| Read next element. More...
CollectionType::Type | GetType ()
| Get collection type. More...
int32_t | GetSize ()
| Get collection size. More...
bool | IsNull ()
| Check whether collection is NULL. More...

## Detailed Description

### template<typename T>
class ignite::binary::BinaryCollectionReader< T >

Binary collection reader.

Can be used to read collection of values of the specific type one by one.

Use GetNext() method to read array value by value while HasNext() method returns true.

## Constructor & Destructor Documentation

## ◆ BinaryCollectionReader()

template<typename T>

ignite::binary::BinaryCollectionReader< T >::BinaryCollectionReader | ( | impl::binary::BinaryReaderImpl * | impl,
|  | int32_t | id,
|  | const CollectionType::Type | type,
|  | int32_t | size
| ) |  |
| inline

Constructor.

Internal call. Should not be used by user.

Parameters

  impl | Reader implementation.
  id | Identifier.
  type | Collection type.
  size | Collection size.

## Member Function Documentation

## ◆ GetNext()

template<typename T>

T ignite::binary::BinaryCollectionReader< T >::GetNext | ( |  | ) |
| inline

Read next element.

Returns
  Next element.

Exceptions

  IgniteError | if there is no element to read.

## ◆ GetSize()

template<typename T>

int32_t ignite::binary::BinaryCollectionReader< T >::GetSize | ( |  | ) |
| inline

Get collection size.

Returns
  Size or -1 if collection is NULL.

## ◆ GetType()

template<typename T>

CollectionType::Type ignite::binary::BinaryCollectionReader< T >::GetType | ( |  | ) |
| inline

Get collection type.

Returns
  Collection type. See CollectionType for the list of available values and their description.

## ◆ HasNext()

template<typename T>

bool ignite::binary::BinaryCollectionReader< T >::HasNext | ( |  | ) |
| inline

Check whether next element is available for read.

Returns
  True if available.

## ◆ IsNull()

template<typename T>

bool ignite::binary::BinaryCollectionReader< T >::IsNull | ( |  | ) |
| inline

Check whether collection is NULL.

Returns
  True if the collection is NULL.

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

- binary_containers.h