summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authorSrivardhan Hebbar <sri.hebbar@samsung.com>2014-12-22 15:08:41 +0100
committerCedric BAIL <cedric@osg.samsung.com>2014-12-22 15:09:59 +0100
commit701f7b073761a19acb0ff37ef8ab7d6bda6d34b3 (patch)
tree2d9415b14319ef866e85e5b76f75d0de36c1b3f5 /src/lib
parent62a6db2dace24315ceeb344b01b4d5c6dd3b32c7 (diff)
eina: add an example to demonstrate different eina insert and sort functions.
Summary: While going through eina for understanding, wrote a program to understand he differences between different eina inarray functions. Thought, this might be useful for others too, so adding the same. Signed-off-by: Srivardhan Hebbar <sri.hebbar@samsung.com> Reviewers: devilhorns Subscribers: cedric Differential Revision: https://phab.enlightenment.org/D1803 Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/eina/eina_inarray.h32
1 files changed, 32 insertions, 0 deletions
diff --git a/src/lib/eina/eina_inarray.h b/src/lib/eina/eina_inarray.h
index 34e7380841..2f95665049 100644
--- a/src/lib/eina/eina_inarray.h
+++ b/src/lib/eina/eina_inarray.h
@@ -149,6 +149,38 @@
149 */ 149 */
150 150
151/** 151/**
152 * @page eina_inarray_example_03 Eina inline array insert, sort and search
153 * @dontinclude eina_inarray_03.c
154 *
155 * This example creates an inline array of integers, and demonstrates the
156 * difference between eina_inarray_insert and eina_inarray_sort, and
157 * eina_inarray_search and eina_inarray_search_sort.
158 * @ref eina_inarray_example_01.
159 *
160 * We start with some variable declarations and eina initialization:
161 * @skip int
162 * @until eina_init
163 *
164 * We then create the array much like we did on @ref eina_inarray_example_01 :
165 * @until inarray_new
166 *
167 * We then add element using eina_inarray_insert and print. Then remove that
168 * element and add again using eina_inarray_insert_sorted and prints. This
169 * shows the 2 different positions the elment gets added. Then searches an
170 * element in the unsorted array using eina_inarray_search, then sorts the
171 * array and then searches the same element using eina_inarray_search_sorted.
172 * @until }
173 *
174 * The source for this example: @ref eina_inarray_03_c
175 */
176
177/**
178 * @page eina_inarray_03_c eina_inarray_03.c
179 * @include eina_inarray_03.c
180 * @example eina_inarray_03.c
181 */
182
183/**
152 * @defgroup Eina_Inline_Array_Group Inline Array 184 * @defgroup Eina_Inline_Array_Group Inline Array
153 * @ingroup Eina_Containers_Group 185 * @ingroup Eina_Containers_Group
154 * @since 1.2 186 * @since 1.2