| Apache Ignite C++

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

Binary array writer. More...

`#include <binary_containers.h>`

## Public Member Functions
| BinaryArrayWriter (impl::binary::BinaryWriterImpl *impl, int32_t id)
| Constructor. More...
void | Write (const T &val)
| Write a value. More...
void | Close ()
| Close the writer. More...

## Detailed Description

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

Binary array writer.

Can be used to write array of values of the specific type one by one.

Use Write() method to write array value by value, then finilize the writing by calling Close() method. Once the Close() method have been called, instance is not usable and will throw an IgniteError on any subsequent attempt to use it.

## Constructor & Destructor Documentation

## ◆ BinaryArrayWriter()

template<typename T >

ignite::binary::BinaryArrayWriter< T >::BinaryArrayWriter | ( | impl::binary::BinaryWriterImpl * | impl,
|  | int32_t | id
| ) |  |
| inline

Constructor.

Internal call. Should not be used by user.

Parameters

  impl | Writer implementation.
  id | Identifier.

## Member Function Documentation

## ◆ Close()

template<typename T >

void ignite::binary::BinaryArrayWriter< T >::Close | ( |  | ) |
| inline

Close the writer.

This method should be called to finilize writing of the array.

Exceptions

  IgniteError | if the writer instance is closed already.

## ◆ Write()

template<typename T >

void ignite::binary::BinaryArrayWriter< T >::Write | ( | const T & | val | ) |
| inline

Write a value.

Parameters

  val | Value to write.

Exceptions

  IgniteError | if the writer instance is closed already.

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

- binary_containers.h