Wiki page arrays.md changed with summary [] by Paul
This commit is contained in:
parent
58b51ba38a
commit
10c1780195
|
@ -4,8 +4,7 @@
|
|||
|
||||
# Arrays #
|
||||
|
||||
An array is a data type which describes an ordered collection of values. The
|
||||
values are accessed by their index.
|
||||
An array is a data type which describes an ordered collection of values. The values are accessed by their index.
|
||||
|
||||
|INDEX |VALUE |
|
||||
|------|------|
|
||||
|
@ -153,7 +152,7 @@ int remove_array()
|
|||
[...]
|
||||
```
|
||||
|
||||
### Completely Wipe an Array Out ###
|
||||
### Wiping all Data from an Array ###
|
||||
|
||||
Use the ``eina_array_flush()`` function. This function sets the count and total members of an array to 0, and frees and sets its data members to ``NULL``. For performance reasons, there is no array check. If the value is ``NULL`` or invalid, the program can crash. The only parameter of this function is a pointer to the ``Eina_Array`` array you want to flush.
|
||||
|
||||
|
@ -203,7 +202,7 @@ nb_elm = eina_array_count(array);
|
|||
|
||||
You can use various methods:
|
||||
|
||||
#### Using the ```ITER_NEXT`` iterator ####
|
||||
#### Using the ``ITER_NEXT`` iterator ####
|
||||
|
||||
You can use the iterator by calling the macro ``EINA_ARRAY_ITER_NEXT()``. It takes the array to iterate as the first parameter, a counter for the current index during the iteration, and a variable of the same type as the item data and an ``Eina_Iterator``. To use it, declare an ``Eina_Iterator``, an ``int`` counter, and, for example, a ``char *`` item if your array contains strings.
|
||||
|
||||
|
|
Loading…
Reference in New Issue