- Main Page
- Related Pages
- Modules
- Namespaces
- Data Structures
- Files
- Examples

- Data Structures
- Data Structure Index
- Class Hierarchy
- Data Fields

Public Member Functions
efl::eina::inarray< T > Class Template Reference
Eina C++Eina C++ » | Data Types » Containers » Inline Array Eina C++Eina C++ » | Data Types » | Containers

Inline array class. More...

## Public Member Functions
| inarray (Eina_Inarray *array)
| Create a new object from a handle to a native Eina_Inarray. More...
| inarray ()
| Default constructor. More...
| inarray (typename _base_type::size_type n, typename _base_type::value_type const &t)
| Construct an array object with `n` copies of `t`. More...
template<typename InputIterator >
| inarray (InputIterator i, InputIterator const &j, typename eina::enable_if<!eina::is_integral< InputIterator >::value >::type *=0)
| Create a inline array with elements from the given range. More...

## Detailed Description

### template<typename T>
class efl::eina::inarray< T >

Inline array class.

It provides an OOP interface to the `Eina_Inarray` functions, and automatically take care of allocating and deallocating resources using the RAII programming idiom.

It also provides additional member functions to facilitate the access to the array content, much like a STL vector.

## Constructor & Destructor Documentation

template<typename T>

efl::eina::inarray< T >::inarray | ( | Eina_Inarray * | array | ) |
| inline

Create a new object from a handle to a native Eina_Inarray.

Parameters

  array | Handle to a native Eina_Inarray.

This constructor wraps a pre-allocated Eina_Inarray providing an OOP interface to it.

Warning
  It is important to note that the created object gains ownership of the handle, deallocating it at destruction time.

template<typename T>

efl::eina::inarray< T >::inarray | ( |  | ) |
| inline

Default constructor.

Creates an empty array.

template<typename T>

efl::eina::inarray< T >::inarray | ( | typename _base_type::size_type | n,
|  | typename _base_type::value_type const & | t
| ) |  |
| inline

Construct an array object with `n` copies of `t`.

Parameters

  n | Number of elements.
  t | Value to be copied to each element.

This constructor creates an inline array with `n` elements, each one as a copy of `t`.

template<typename T>
template<typename InputIterator >

efl::eina::inarray< T >::inarray | ( | InputIterator | i,
|  | InputIterator const & | j,
|  | typename eina::enable_if<!eina::is_integral< InputIterator >::value >::type * | = `0`
| ) |  |
| inline

Create a inline array with elements from the given range.

Parameters

  i | Iterator to the initial position. The element pointed by this iterator will be copied.
  j | Iterator to the final position. The element pointed by this iterator will NOT be copied.

This constructor creates a inline array with copies of the elements between `i` and `j` in the same order.

Note
  The ending element (pointed by `j`) is not copied.