Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
fixing the doc...
authoralegrand <alegrand@48e7efb5-ca39-0410-a469-dd3cf9ba447f>
Fri, 26 Aug 2005 01:43:22 +0000 (01:43 +0000)
committeralegrand <alegrand@48e7efb5-ca39-0410-a469-dd3cf9ba447f>
Fri, 26 Aug 2005 01:43:22 +0000 (01:43 +0000)
git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/simgrid/simgrid/trunk@1667 48e7efb5-ca39-0410-a469-dd3cf9ba447f

doc/FAQ.doc
doc/index.doc
doc/module-xbt.doc
include/xbt/fifo.h
src/xbt/fifo.c

index efd0684..04ba62e 100644 (file)
@@ -147,7 +147,7 @@ You are at the right place... Having a look to these <a
 href="http://graal.ens-lyon.fr/~alegrand/articles/Simgrid-Introduction.pdf">slides</a>
 may give you some insights on what SimGrid can help you to do and what
 are its limitations. Then you definitely should read the \ref
 href="http://graal.ens-lyon.fr/~alegrand/articles/Simgrid-Introduction.pdf">slides</a>
 may give you some insights on what SimGrid can help you to do and what
 are its limitations. Then you definitely should read the \ref
-MSG_examples. There is also a mailing list: <simgrid-user#lists.gforge.inria.fr>.
+MSG_examples. There is also a mailing list: <simgrid-user@lists.gforge.inria.fr>.
 
 \subsection faq_generic Building a generic simulator
 
 
 \subsection faq_generic Building a generic simulator
 
index 8e8396b..fe46817 100644 (file)
@@ -74,7 +74,7 @@ The base of the whole toolkit is constituted by the <b>\ref XBT_API
 (eXtended Bundle of Tools)</b>.
 
 It is a portable library providing some grounding features such as \ref
 (eXtended Bundle of Tools)</b>.
 
 It is a portable library providing some grounding features such as \ref
-XBT_log, \ref XBT_ex, \ref XBT_error and \ref XBT_config. XBT also encompass
+XBT_log, \ref XBT_ex and \ref XBT_config. XBT also encompass
 the following convenient datastructures: \ref XBT_dynar, \ref XBT_fifo, \ref
 XBT_dict, \ref XBT_heap, \ref XBT_set and \ref XBT_swag.
 
 the following convenient datastructures: \ref XBT_dynar, \ref XBT_fifo, \ref
 XBT_dict, \ref XBT_heap, \ref XBT_set and \ref XBT_swag.
 
index 3619f7b..da1989c 100644 (file)
      * \brief A data container consisting in \ref XBT_dict and \ref XBT_dynar
      */
     
      * \brief A data container consisting in \ref XBT_dict and \ref XBT_dynar
      */
     
-/**       \addtogroup XBT_fifo
-          \ingroup XBT_API */
+    /** \defgroup XBT_fifo A generic workqueue
+      *  \brief This section describes the API to generic workqueue. These functions
+      *   provide the same kind of functionnality as dynamic arrays but in time O(1). 
+      *   However these functions use malloc/free way too much often.
+      */
          
     /** @defgroup XBT_swag A O(1) set datatype
      *  @brief a O(1) set based on linked lists
          
     /** @defgroup XBT_swag A O(1) set datatype
      *  @brief a O(1) set based on linked lists
index 8971ab5..a06a7e8 100644 (file)
@@ -7,45 +7,57 @@
 
 #ifndef _XBT_FIFO_H
 #define _XBT_FIFO_H
 
 #ifndef _XBT_FIFO_H
 #define _XBT_FIFO_H
+#include "xbt/misc.h" /* BEGIN_DECL */
+
+BEGIN_DECL()
+
+/** \addtogroup XBT_fifo
+ *  @{ */
+
+/** @name 1. Constructor/destructor
+ *  @{
+ */
 
 /** \brief  Bucket structure 
 
 /** \brief  Bucket structure 
- *  \ingroup XBT_fifo
 */
 typedef struct xbt_fifo_item *xbt_fifo_item_t;
 
 /** \brief  FIFO structure
 */
 typedef struct xbt_fifo_item *xbt_fifo_item_t;
 
 /** \brief  FIFO structure
- *  \ingroup XBT_fifo
 */
 typedef struct xbt_fifo *xbt_fifo_t;
 
 */
 typedef struct xbt_fifo *xbt_fifo_t;
 
-/* API */
 xbt_fifo_t xbt_fifo_new(void);
 void xbt_fifo_free(xbt_fifo_t);
 xbt_fifo_t xbt_fifo_new(void);
 void xbt_fifo_free(xbt_fifo_t);
+/** @} */
 
 
+/** @name 2. Perl-like functions
+ *  @{
+ */
 xbt_fifo_item_t xbt_fifo_push(xbt_fifo_t, void *);
 void *xbt_fifo_pop(xbt_fifo_t);
 xbt_fifo_item_t xbt_fifo_unshift(xbt_fifo_t, void *);
 void *xbt_fifo_shift(xbt_fifo_t);
 xbt_fifo_item_t xbt_fifo_push(xbt_fifo_t, void *);
 void *xbt_fifo_pop(xbt_fifo_t);
 xbt_fifo_item_t xbt_fifo_unshift(xbt_fifo_t, void *);
 void *xbt_fifo_shift(xbt_fifo_t);
-
-void xbt_fifo_push_item(xbt_fifo_t, xbt_fifo_item_t);
-xbt_fifo_item_t xbt_fifo_pop_item(xbt_fifo_t);
-void xbt_fifo_unshift_item(xbt_fifo_t, xbt_fifo_item_t);
-xbt_fifo_item_t xbt_fifo_shift_item(xbt_fifo_t);
-
-void xbt_fifo_remove(xbt_fifo_t, void *);
-void xbt_fifo_remove_item(xbt_fifo_t, xbt_fifo_item_t);
-
+int xbt_fifo_size(xbt_fifo_t);
 int xbt_fifo_is_in(xbt_fifo_t, void *);
 int xbt_fifo_is_in(xbt_fifo_t, void *);
+/** @} */
 
 
-void **xbt_fifo_to_array(xbt_fifo_t);
-xbt_fifo_t xbt_fifo_copy(xbt_fifo_t);
+/** @name 3. Manipulating directly items
+ *
+ *  @{
+ */
 
 xbt_fifo_item_t xbt_fifo_newitem(void);
 void xbt_fifo_set_item_content(xbt_fifo_item_t, void *);
 void *xbt_fifo_get_item_content(xbt_fifo_item_t);
 void xbt_fifo_freeitem(xbt_fifo_item_t);
 
 
 xbt_fifo_item_t xbt_fifo_newitem(void);
 void xbt_fifo_set_item_content(xbt_fifo_item_t, void *);
 void *xbt_fifo_get_item_content(xbt_fifo_item_t);
 void xbt_fifo_freeitem(xbt_fifo_item_t);
 
-int xbt_fifo_size(xbt_fifo_t);
+void xbt_fifo_push_item(xbt_fifo_t, xbt_fifo_item_t);
+xbt_fifo_item_t xbt_fifo_pop_item(xbt_fifo_t);
+void xbt_fifo_unshift_item(xbt_fifo_t, xbt_fifo_item_t);
+xbt_fifo_item_t xbt_fifo_shift_item(xbt_fifo_t);
+
+void xbt_fifo_remove(xbt_fifo_t, void *);
+void xbt_fifo_remove_item(xbt_fifo_t, xbt_fifo_item_t);
 
 xbt_fifo_item_t xbt_fifo_getFirstItem(xbt_fifo_t l);
 xbt_fifo_item_t xbt_fifo_getNextItem(xbt_fifo_item_t i);
 
 xbt_fifo_item_t xbt_fifo_getFirstItem(xbt_fifo_t l);
 xbt_fifo_item_t xbt_fifo_getNextItem(xbt_fifo_item_t i);
@@ -53,7 +65,6 @@ xbt_fifo_item_t xbt_fifo_getPrevItem(xbt_fifo_item_t i);
 
 /** 
  * \brief List iterator
 
 /** 
  * \brief List iterator
- * \ingroup XBT_fifo
  * asserts and stuff
  * \param f a list (#xbt_fifo_t)
  * \param i a bucket (#xbt_fifo_item_t)
  * asserts and stuff
  * \param f a list (#xbt_fifo_t)
  * \param i a bucket (#xbt_fifo_item_t)
@@ -67,5 +78,17 @@ xbt_fifo_item_t xbt_fifo_getPrevItem(xbt_fifo_item_t i);
      ((i)?(n=(type)(xbt_fifo_get_item_content(i))):(NULL));             \
        i=xbt_fifo_getNextItem(i))
 
      ((i)?(n=(type)(xbt_fifo_get_item_content(i))):(NULL));             \
        i=xbt_fifo_getNextItem(i))
 
+/** @} */
+
+/** @name 4. Miscanaleous
+ *
+ *  @{
+ */
+void **xbt_fifo_to_array(xbt_fifo_t);
+xbt_fifo_t xbt_fifo_copy(xbt_fifo_t);
+/** @} */
+
+END_DECL()
 
 
+/** @} */
 #endif                         /* _XBT_FIFO_H */
 #endif                         /* _XBT_FIFO_H */
index ed8b30e..80922f1 100644 (file)
 
 /*XBT_LOG_NEW_DEFAULT_SUBCATEGORY(fifo,xbt,"FIFO"); UNUSED SO FAR */
 
 
 /*XBT_LOG_NEW_DEFAULT_SUBCATEGORY(fifo,xbt,"FIFO"); UNUSED SO FAR */
 
-/** \defgroup XBT_fifo A generic workqueue
-  *  \brief This section describes the API to generic workqueue. These functions
-  *   provide the same kind of functionnality as dynamic arrays but in time O(1). 
-  *   However these functions use malloc/free a way too much often.
-  */
-
-/** \name Functions 
- *  \ingroup XBT_fifo
- */
-/* @{ */
-
 /** Constructor
  * \return a new fifo
  */
 /** Constructor
  * \return a new fifo
  */