From 0c41763f5104b8ccb38f56ca1ce62d4da764d5ca Mon Sep 17 00:00:00 2001 From: Mike McCormack Date: Fri, 25 Nov 2011 17:28:01 +0900 Subject: [PATCH] [db] more docs to header --- src/lib/Elementary.h.in | 80 ++++++++++++++++++++++++++++++++++++ src/lib/elm_store.c | 107 ------------------------------------------------ 2 files changed, 80 insertions(+), 107 deletions(-) diff --git a/src/lib/Elementary.h.in b/src/lib/Elementary.h.in index 01c41ad..324b33e 100644 --- a/src/lib/Elementary.h.in +++ b/src/lib/Elementary.h.in @@ -27880,18 +27880,95 @@ extern "C" { #define ELM_STORE_ITEM_MAPPING_END { ELM_STORE_ITEM_MAPPING_NONE, NULL, 0, { .empty = { EINA_TRUE } } } #define ELM_STORE_ITEM_MAPPING_OFFSET(st, it) offsetof(st, it) + /** + * dbsystem Store object + * + * @addtogroup DBStore + * @{ + * + * @return The new object or NULL if it cannot be created + */ EAPI Elm_Store *elm_store_dbsystem_new(void); + /** + * Sets the item count of a store + * + * @param st The store object + * @param count The item count of an store + */ EAPI void elm_store_item_count_set(Elm_Store *st, int count) EINA_ARG_NONNULL(1); + /** + * Set the select func that select the state of a list item whether true or false + * + * @param st The store object + * @param func The select cb function of an store + * @param data The new data pointer to set + */ EAPI void elm_store_item_select_func_set(Elm_Store *st, Elm_Store_Item_Select_Cb func, const void *data) EINA_ARG_NONNULL(1); + /** + * Sets the sort func that sort the item with a next in the list + * + * @param st The store object + * @param func The sort cb function of an store + * @param data The new data pointer to set + */ EAPI void elm_store_item_sort_func_set(Elm_Store *st, Elm_Store_Item_Sort_Cb func, const void *data) EINA_ARG_NONNULL(1); + /** + * Set the store item free func + * + * @param st The store object + * @param func The free cb function of an store + * @param data The new data pointer to set + */ EAPI void elm_store_item_free_func_set(Elm_Store *st, Elm_Store_Item_Free_Cb func, const void *data) EINA_ARG_NONNULL(1); + /** + * Get the item index that included header items + * + * @param sti The store item object + * @return The item index in genlist + */ EAPI int elm_store_item_data_index_get(const Elm_Store_Item *sti) EINA_ARG_NONNULL(1); + /** + * Get the DB pointer of an item + * + * @param sti The store item object + * @return The DB pointer of item + */ EAPI void *elm_store_dbsystem_db_get(const Elm_Store_Item *sti) EINA_ARG_NONNULL(1); + /** + * Set the DB pointer of an item + * + * @param sti The store item object + * @parm p_db The DB pointer of item + */ EAPI void elm_store_dbsystem_db_set(Elm_Store *store, void *pDB) EINA_ARG_NONNULL(1); + /** + */ EAPI int elm_store_item_index_get(const Elm_Store_Item *sti) EINA_ARG_NONNULL(1); + /** + * Append the item to the genlist + * + * @param st The store object + * @param info The store item info dbsystem object + * @return The item of store + */ EAPI Elm_Store_Item *elm_store_item_add(Elm_Store *st, Elm_Store_Item_Info *info) EINA_ARG_NONNULL(1); + /** + * Realize the visible items to the screen + * + * @param st The store object + */ EAPI void elm_store_item_update(Elm_Store_Item *sti) EINA_ARG_NONNULL(1); + /** + * Realize the item to the screen + * + * @param sti The store item object + */ EAPI void elm_store_visible_items_update(Elm_Store *st) EINA_ARG_NONNULL(1); + /** + * Delete the item of genlist + * + * @param sti The store item object + */ EAPI void elm_store_item_del(Elm_Store_Item *sti) EINA_ARG_NONNULL(1); EAPI void elm_store_free(Elm_Store *st); EAPI Elm_Store *elm_store_filesystem_new(void); @@ -27915,6 +27992,9 @@ extern "C" { EAPI void *elm_store_item_data_get(Elm_Store_Item *sti) EINA_ARG_NONNULL(1); EAPI const Elm_Store *elm_store_item_store_get(const Elm_Store_Item *sti) EINA_ARG_NONNULL(1); EAPI const Elm_Genlist_Item *elm_store_item_genlist_item_get(const Elm_Store_Item *sti) EINA_ARG_NONNULL(1); + /** + * @} + */ /** * @defgroup SegmentControl SegmentControl diff --git a/src/lib/elm_store.c b/src/lib/elm_store.c index 46915e0..4265bda 100644 --- a/src/lib/elm_store.c +++ b/src/lib/elm_store.c @@ -1686,13 +1686,6 @@ _store_free(Elm_Store *st) if(std->p_db) eina_stringshare_del(std->p_db); } -/** - * Add a new dbsystem Store object - * - * @return The new object or NULL if it cannot be created - * - * @ingroup Store - */ EAPI Elm_Store * elm_store_dbsystem_new(void) { @@ -1705,14 +1698,6 @@ elm_store_dbsystem_new(void) return &std->base; } -/** - * Sets the item count of a store - * - * @param st The store object - * @param count The item count of an store - * - * @ingroup Store - */ EAPI void elm_store_item_count_set(Elm_Store *st, int count) { @@ -1721,15 +1706,6 @@ elm_store_item_count_set(Elm_Store *st, int count) } -/** - * Set the select func that select the state of a list item whether true or false - * - * @param st The store object - * @param func The select cb function of an store - * @param data The new data pointer to set - * - * @ingroup Store - */ EAPI void elm_store_item_select_func_set(Elm_Store *st, Elm_Store_Item_Select_Cb func, const void *data) { @@ -1738,15 +1714,6 @@ elm_store_item_select_func_set(Elm_Store *st, Elm_Store_Item_Select_Cb func, con st->cb.item_select.data = (void *)data; } -/** - * Sets the sort func that sort the item with a next in the list - * - * @param st The store object - * @param func The sort cb function of an store - * @param data The new data pointer to set - * - * @ingroup Store - */ EAPI void elm_store_item_sort_func_set(Elm_Store *st, Elm_Store_Item_Sort_Cb func, const void *data) { @@ -1755,15 +1722,6 @@ elm_store_item_sort_func_set(Elm_Store *st, Elm_Store_Item_Sort_Cb func, const v st->cb.item_sort.data = (void *)data; } -/** - * Set the store item free func - * - * @param st The store object - * @param func The free cb function of an store - * @param data The new data pointer to set - * - * @ingroup Store - */ EAPI void elm_store_item_free_func_set(Elm_Store *st, Elm_Store_Item_Free_Cb func, const void *data) { @@ -1772,14 +1730,6 @@ elm_store_item_free_func_set(Elm_Store *st, Elm_Store_Item_Free_Cb func, const v st->cb.item_free.data = (void *)data; } -/** - * Get the item index that included header items - * - * @param sti The store item object - * @return The item index in genlist - * - * @ingroup Store - */ EAPI int elm_store_item_index_get(const Elm_Store_Item *sti) { @@ -1804,14 +1754,6 @@ elm_store_item_index_get(const Elm_Store_Item *sti) return -1; } -/** - * Get the item index of real data that don't included header items - * - * @param sti The store item object - * @return The real item index - * - * @ingroup Store - */ EAPI int elm_store_item_data_index_get(const Elm_Store_Item *sti) { @@ -1836,14 +1778,6 @@ elm_store_item_data_index_get(const Elm_Store_Item *sti) return -1; } -/** - * Get the DB pointer of an item - * - * @param sti The store item object - * @return The DB pointer of item - * - * @ingroup Store - */ EAPI void * elm_store_dbsystem_db_get(const Elm_Store_Item *sti) { @@ -1855,14 +1789,6 @@ elm_store_dbsystem_db_get(const Elm_Store_Item *sti) return std->p_db; } -/** - * Set the DB pointer of an item - * - * @param sti The store item object - * @parm p_db The DB pointer of item - * - * @ingroup Store - */ EAPI void elm_store_dbsystem_db_set(Elm_Store *store, void *p_db) { @@ -1882,15 +1808,6 @@ elm_store_dbsystem_db_set(Elm_Store *store, void *p_db) store, EINA_TRUE); } -/** - * Append the item to the genlist - * - * @param st The store object - * @param info The store item info dbsystem object - * @return The item of store - * - * @ingroup Store - */ EAPI Elm_Store_Item * elm_store_item_add(Elm_Store *st, Elm_Store_Item_Info *info) { @@ -1930,13 +1847,6 @@ elm_store_item_add(Elm_Store *st, Elm_Store_Item_Info *info) } } -/** - * Realize the visible items to the screen - * - * @param st The store object - * - * @ingroup Store - */ EAPI void elm_store_visible_items_update(Elm_Store *st) { @@ -1953,13 +1863,6 @@ elm_store_visible_items_update(Elm_Store *st) } } -/** - * Realize the item to the screen - * - * @param sti The store item object - * - * @ingroup Store - */ EAPI void elm_store_item_update(Elm_Store_Item *sti) { @@ -1980,13 +1883,6 @@ elm_store_item_update(Elm_Store_Item *sti) } } -/** - * Delete the item of genlist - * - * @param sti The store item object - * - * @ingroup Store - */ EAPI void elm_store_item_del(Elm_Store_Item *sti) { @@ -2041,6 +1937,3 @@ elm_store_item_del(Elm_Store_Item *sti) if(!deleted) printf(" Not deleted because it does not existed in the genlist \n"); } } - -// TODO: END -DBsystem store - -- 2.7.4