eina-cxx: Added range types for containers
authorFelipe Magno de Almeida <felipe@expertisesolutions.com.br>
Mon, 10 Mar 2014 03:24:29 +0000 (12:24 +0900)
committerCedric BAIL <cedric.bail@samsung.com>
Mon, 10 Mar 2014 03:35:00 +0000 (12:35 +0900)
commit5942207b25d746585c2b9eb93393e1af9dcb0ad7
treea330ff947344b205d86453c41cc90e9ffe4a5a0f
parent6bd03923394c77d8b19c54bcb7fd31cd8a1303a0
eina-cxx: Added range types for containers

Summary:
Added inarray, inlist, ptr_array and ptr_list's range types named: range_inarray, range_inlist, range_ptr_array and range_ptr_list.

Each has two "flavours": mutable and not mutable. The const versions are parameterized by a const parameter. For example: range_ptr_list<int const> and the mutable doesn't have the const, so: range_ptr_list<int>.

The difference between the two is that the const versions can't modify the elements from the sequence, while the mutable allows so. Also, the const receives a Eina_Array const* while the mutable must have a Eina_Array*.

Reviewers: cedric

CC: savio, cedric
Differential Revision: https://phab.enlightenment.org/D613
src/bindings/eina_cxx/eina_inarray.hh
src/bindings/eina_cxx/eina_inlist.hh
src/bindings/eina_cxx/eina_ptrarray.hh
src/bindings/eina_cxx/eina_ptrlist.hh
src/bindings/eina_cxx/eina_range_types.hh [new file with mode: 0644]
src/tests/eina_cxx/eina_cxx_test_inarray.cc
src/tests/eina_cxx/eina_cxx_test_inlist.cc
src/tests/eina_cxx/eina_cxx_test_ptrarray.cc
src/tests/eina_cxx/eina_cxx_test_ptrlist.cc