-For the plugin *tic-tac-toe* it is the function **get_new_board**.
-The function **get_new_board** creates a new board and set its
-count of use to 1. The boards are counting their count of use
-to free there ressources when no more used.
-
-The third argument if the function that frees the context.
-For the plugin *tic-tac-toe* it is the function **release_board**.
-The function **release_board** decrease the the count of use of
-the board given as argument. If the use count decrease to zero,
-the board data are freed.
-
-The definition of the other functions for dealing with contexts are:
-
- /*
- * Gets the pointer stored by the plugin for the session of 'req'.
- * When the plugin has not yet recorded a pointer, NULL is returned.
- */
- void *afb_req_context_get(struct afb_req req);
-
- /*
- * Stores for the plugin the pointer 'context' to the session of 'req'.
- * The function 'free_context' will be called when the session is closed
- * or if plugin stores an other pointer.
- */
- void afb_req_context_set(struct afb_req req, void *context, void (*free_context)(void*));
-
- /*
- * Frees the pointer stored by the plugin for the session of 'req'
- * and sets it to NULL.
- *
- * Shortcut for: afb_req_context_set(req, NULL, NULL)
- */
- static inline void afb_req_context_clear(struct afb_req req)
- {
- afb_req_context_set(req, NULL, NULL);
- }
-
-### Sending the reply to a request
-
-Two kinds of replies can be made: successful replies and
-failure replies.
-
-> Sending a reply to a request must be done at most one time.
-
-The two functions to send a reply of kind "success" are
-**afb_req_success** and **afb_req_success_f**.
-
- /*
- * Sends a reply of kind success to the request 'req'.
- * The status of the reply is automatically set to "success".
- * Its send the object 'obj' (can be NULL) with an
- * informationnal comment 'info (can also be NULL).
- *
- * For conveniency, the function calls 'json_object_put' for 'obj'.
- * Thus, in the case where 'obj' should remain available after
- * the function returns, the function 'json_object_get' shall be used.
- */
- void afb_req_success(struct afb_req req, struct json_object *obj, const char *info);
-
- /*
- * Same as 'afb_req_success' but the 'info' is a formatting
- * string followed by arguments.
- *
- * For conveniency, the function calls 'json_object_put' for 'obj'.
- * Thus, in the case where 'obj' should remain available after
- * the function returns, the function 'json_object_get' shall be used.
- */
- void afb_req_success_f(struct afb_req req, struct json_object *obj, const char *info, ...);
-
-The two functions to send a reply of kind "failure" are
-**afb_req_fail** and **afb_req_fail_f**.
-
- /*
- * Sends a reply of kind failure to the request 'req'.
- * The status of the reply is set to 'status' and an
- * informationnal comment 'info' (can also be NULL) can be added.
- *
- * Note that calling afb_req_fail("success", info) is equivalent
- * to call afb_req_success(NULL, info). Thus even if possible it
- * is strongly recommanded to NEVER use "success" for status.
- *
- * For conveniency, the function calls 'json_object_put' for 'obj'.
- * Thus, in the case where 'obj' should remain available after
- * the function returns, the function 'json_object_get' shall be used.
- */
- void afb_req_fail(struct afb_req req, const char *status, const char *info);
-
- /*
- * Same as 'afb_req_fail' but the 'info' is a formatting
- * string followed by arguments.
- *
- * For conveniency, the function calls 'json_object_put' for 'obj'.
- * Thus, in the case where 'obj' should remain available after
- * the function returns, the function 'json_object_get' shall be used.
- */
- void afb_req_fail_f(struct afb_req req, const char *status, const char *info, ...);
-
-> For conveniency, these functions call **json_object_put** to release the object **obj**
-> that they send. Then **obj** can not be used after calling one of these reply functions.
-> When it is not the expected behaviour, calling the function **json_object_get** on the object **obj**
-> before cancels the effect of **json_object_put**.
+For plugin *tic-tac-toe* (function **get_new_board**).
+The function **get_new_board** creates a new board and set usage its count to 1.
+The boards are checking usage count to free resources when not used.
+
+The third argument is a function that frees context resources.
+For plugin *tic-tac-toe* (function **release_board**).
+The function **release_board** decrease usage count of the board passed in argument.
+When usage count falls to zero, data board are freed.
+
+Definition of other functions dealing with contexts:
+
+```C
+/*
+ * Gets the pointer stored by the plugin for the session of 'req'.
+ * When the plugin has not yet recorded a pointer, NULL is returned.
+ */
+void *afb_req_context_get(struct afb_req req);
+
+/*
+ * Stores for the plugin the pointer 'context' to the session of 'req'.
+ * The function 'free_context' will be called when the session is closed
+ * or if plugin stores an other pointer.
+ */
+void afb_req_context_set(struct afb_req req, void *context, void (*free_context)(void*));
+
+/*
+ * Frees the pointer stored by the plugin for the session of 'req'
+ * and sets it to NULL.
+ *
+ * Shortcut for: afb_req_context_set(req, NULL, NULL)
+ */
+static inline void afb_req_context_clear(struct afb_req req)
+{
+ afb_req_context_set(req, NULL, NULL);
+}
+```
+
+### Sending reply to a request
+
+Two kinds of replies: successful or failure.
+
+> Sending a reply to a request MUST be done once and only once.
+
+It exists two functions for "success" replies: **afb_req_success** and **afb_req_success_f**.
+
+```C
+/*
+ * Sends a reply of kind success to the request 'req'.
+ * The status of the reply is automatically set to "success".
+ * Its send the object 'obj' (can be NULL) with an
+ * informationnal comment 'info (can also be NULL).
+ *
+ * For conveniency, the function calls 'json_object_put' for 'obj'.
+ * Thus, in the case where 'obj' should remain available after
+ * the function returns, the function 'json_object_get' shall be used.
+ */
+void afb_req_success(struct afb_req req, struct json_object *obj, const char *info);
+
+/*
+ * Same as 'afb_req_success' but the 'info' is a formatting
+ * string followed by arguments.
+ *
+ * For conveniency, the function calls 'json_object_put' for 'obj'.
+ * Thus, in the case where 'obj' should remain available after
+ * the function returns, the function 'json_object_get' shall be used.
+ */
+void afb_req_success_f(struct afb_req req, struct json_object *obj, const char *info, ...);
+```
+
+It exists two functions for "failure" replies: **afb_req_fail** and **afb_req_fail_f**.
+
+```C
+/*
+ * Sends a reply of kind failure to the request 'req'.
+ * The status of the reply is set to 'status' and an
+ * informational comment 'info' (can also be NULL) can be added.
+ *
+ * Note that calling afb_req_fail("success", info) is equivalent
+ * to call afb_req_success(NULL, info). Thus even if possible it
+ * is strongly recommended to NEVER use "success" for status.
+ *
+ * For conveniency, the function calls 'json_object_put' for 'obj'.
+ * Thus, in the case where 'obj' should remain available after
+ * the function returns, the function 'json_object_get' shall be used.
+ */
+void afb_req_fail(struct afb_req req, const char *status, const char *info);
+
+/*
+ * Same as 'afb_req_fail' but the 'info' is a formatting
+ * string followed by arguments.
+ *
+ * For conveniency, the function calls 'json_object_put' for 'obj'.
+ * Thus, in the case where 'obj' should remain available after
+ * the function returns, the function 'json_object_get' shall be used.
+ */
+void afb_req_fail_f(struct afb_req req, const char *status, const char *info, ...);
+```
+
+> For conveniency, these functions automatically call **json_object_put** to release **obj**.
+> Because **obj** usage count is null after being passed to a reply function, it SHOULD not be used anymore.
+> If exceptionally **obj** needs to remain usable after reply function then using **json_object_get** on **obj**
+> to increase usage count and cancels the effect the **json_object_put** is possible.