]> granicus.if.org Git - apache/commitdiff
Improve highlight and make these doc much more readable.
authorChristophe Jaillet <jailletc36@apache.org>
Fri, 20 Apr 2018 21:12:38 +0000 (21:12 +0000)
committerChristophe Jaillet <jailletc36@apache.org>
Fri, 20 Apr 2018 21:12:38 +0000 (21:12 +0000)
Use the "c" highlight for API description.

(r1829678 in trunk)

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x@1829679 13f79535-47bb-0310-9956-ffa450edef68

docs/manual/mod/mod_slotmem_plain.xml
docs/manual/mod/mod_slotmem_shm.xml

index 6cd8fe58427bfabe52d06a850f6f87dec7a0e5b9..71e933ab982c092dedb610ed4b17133722ed5fa2 100644 (file)
@@ -29,7 +29,7 @@
 <identifier>slotmem_plain_module</identifier>
 
 <summary>
-    <p><code>mod_slotmem_plain</code> is a memory provider which
+    <p><module>mod_slotmem_plain</module> is a memory provider which
     provides for creation and access to a plain memory segment
     in which the datasets are organized in "slots."
     </p>
     <module>mod_slotmem_shm</module>.
     </p>
 
-    <p><code>mod_slotmem_plain</code> provides the following API functions:
+    <p><module>mod_slotmem_plain</module> provides the following API functions:
     </p>
 
-    <dl>
-      <dt>apr_status_t doall(ap_slotmem_instance_t *s, ap_slotmem_callback_fn_t *func, void *data, apr_pool_t *pool)</dt>
-      <dd>call the callback on all worker slots</dd>
+<highlight language="c">
+/* call the callback on all worker slots */
+apr_status_t doall(ap_slotmem_instance_t *s, ap_slotmem_callback_fn_t *func, void *data, apr_pool_t *pool)
 
-      <dt>apr_status_t create(ap_slotmem_instance_t **new, const char *name, apr_size_t item_size, unsigned int item_num, ap_slotmem_type_t type, apr_pool_t *pool)</dt>
-      <dd>create a new slotmem with each item size is item_size.</dd>
+/* create a new slotmem with each item size is item_size */
+apr_status_t create(ap_slotmem_instance_t **new, const char *name, apr_size_t item_size, unsigned int item_num, ap_slotmem_type_t type, apr_pool_t *pool)
 
-      <dt>apr_status_t attach(ap_slotmem_instance_t **new, const char *name, apr_size_t *item_size, unsigned int *item_num, apr_pool_t *pool)</dt>
-      <dd>attach to an existing slotmem.</dd>
+/* attach to an existing slotmem */
+apr_status_t attach(ap_slotmem_instance_t **new, const char *name, apr_size_t *item_size, unsigned int *item_num, apr_pool_t *pool)
 
-      <dt>apr_status_t dptr(ap_slotmem_instance_t *s, unsigned int item_id, void**mem)</dt>
-      <dd>get the direct pointer to the memory associated with this worker slot.</dd>
+/* get the direct pointer to the memory associated with this worker slot */
+apr_status_t dptr(ap_slotmem_instance_t *s, unsigned int item_id, void **mem)
 
-      <dt>apr_status_t get(ap_slotmem_instance_t *s, unsigned int item_id, unsigned char *dest, apr_size_t dest_len)</dt>
-      <dd>get/read the memory from this slot to dest</dd>
+/* get/read the memory from this slot to dest */
+apr_status_t get(ap_slotmem_instance_t *s, unsigned int item_id, unsigned char *dest, apr_size_t dest_len)
 
-      <dt>apr_status_t put(ap_slotmem_instance_t *slot, unsigned int item_id, unsigned char *src, apr_size_t src_len)</dt>
-      <dd>put/write the data from src to this slot</dd>
+/* put/write the data from src to this slot */
+apr_status_t put(ap_slotmem_instance_t *slot, unsigned int item_id, unsigned char *src, apr_size_t src_len)
 
-      <dt>unsigned int num_slots(ap_slotmem_instance_t *s)</dt>
-      <dd>return the total number of slots in the segment</dd>
+/* return the total number of slots in the segment */
+unsigned int num_slots(ap_slotmem_instance_t *s)
 
-      <dt>apr_size_t slot_size(ap_slotmem_instance_t *s)</dt>
-      <dd>return the total data size, in bytes, of a slot in the segment</dd>
+/* return the total data size, in bytes, of a slot in the segment */
+apr_size_t slot_size(ap_slotmem_instance_t *s)
 
-      <dt>apr_status_t grab(ap_slotmem_instance_t *s, unsigned int *item_id);</dt>
-      <dd>grab or allocate the first free slot and mark as in-use (does not do any data copying)</dd>
+/* grab or allocate the first free slot and mark as in-use (does not do any data copying) */
+apr_status_t grab(ap_slotmem_instance_t *s, unsigned int *item_id)
 
-      <dt>apr_status_t fgrab(ap_slotmem_instance_t *s, unsigned int item_id);</dt>
-      <dd>forced grab or allocate the specified slot and mark as in-use (does not do any data copying)</dd>
-        
-     <dt>apr_status_t release(ap_slotmem_instance_t *s, unsigned int item_id);</dt>
-      <dd>release or free a slot and mark as not in-use (does not do any data copying)</dd>
-    </dl>
+/* forced grab or allocate the specified slot and mark as in-use (does not do any data copying) */
+apr_status_t fgrab(ap_slotmem_instance_t *s, unsigned int item_id)
+
+/* release or free a slot and mark as not in-use (does not do any data copying) */
+apr_status_t release(ap_slotmem_instance_t *s, unsigned int item_id)
+</highlight>
 
 </summary>
 
index 4c45aa2c655a487f4d5b67bfb87130e06a4d6d11..5312d12e1d5421f4e1704be67ff79601b3001d38 100644 (file)
@@ -29,7 +29,7 @@
 <identifier>slotmem_shm_module</identifier>
 
 <summary>
-    <p><code>mod_slotmem_shm</code> is a memory provider which
+    <p><module>mod_slotmem_shm</module> is a memory provider which
     provides for creation and access to a shared memory segment
     in which the datasets are organized in "slots."
     </p>
     <directive module="core">DefaultRuntimeDir</directive> directive.
     </p>
 
-    <p><code>mod_slotmem_shm</code> provides the following API functions:
+    <p><module>mod_slotmem_shm</module> provides the following API functions:
     </p>
 
-    <dl>
-      <dt>apr_status_t doall(ap_slotmem_instance_t *s, ap_slotmem_callback_fn_t *func, void *data, apr_pool_t *pool)</dt>
-      <dd>call the callback on all worker slots</dd>
+<highlight language="c">
+/* call the callback on all worker slots */
+apr_status_t doall(ap_slotmem_instance_t *s, ap_slotmem_callback_fn_t *func, void *data, apr_pool_t *pool)
 
-      <dt>apr_status_t create(ap_slotmem_instance_t **new, const char *name, apr_size_t item_size, unsigned int item_num, ap_slotmem_type_t type, apr_pool_t *pool)</dt>
-      <dd>create a new slotmem with each item size is item_size. <code>name</code> is used to generate a filename for the persistent store of
-      the shared memory if configured. Values are:
-       <dl>
-         <dt><code>"none"</code></dt>
-         <dd><code>Anonymous shared memory and no persistent store</code></dd>
-         <dt><code>"file-name"</code></dt>
-         <dd><code>[DefaultRuntimeDir]/file-name</code></dd>
-         <dt><code>"/absolute-file-name"</code></dt>
-         <dd><code>Absolute file name</code></dd>
-       </dl></dd>
+/* create a new slotmem with each item size is item_size. 'name' is used to generate a filename for the persistent
+   store of the shared memory if configured. Values are:
+      "none"                - Anonymous shared memory and no persistent store
+      "file-name"           - [DefaultRuntimeDir]/file-name
+      "/absolute-file-name" - Absolute file name */
+apr_status_t create(ap_slotmem_instance_t **new, const char *name, apr_size_t item_size, unsigned int item_num, ap_slotmem_type_t type, apr_pool_t *pool)
 
-      <dt>apr_status_t attach(ap_slotmem_instance_t **new, const char *name, apr_size_t *item_size, unsigned int *item_num, apr_pool_t *pool)</dt>
-      <dd>attach to an existing slotmem. See <code>create</code> for description of <code>name</code> parameter.</dd>
+/* attach to an existing slotmem. See 'create()' for description of 'name' parameter */
+apr_status_t attach(ap_slotmem_instance_t **new, const char *name, apr_size_t *item_size, unsigned int *item_num, apr_pool_t *pool)
 
-      <dt>apr_status_t dptr(ap_slotmem_instance_t *s, unsigned int item_id, void**mem)</dt>
-      <dd>get the direct pointer to the memory associated with this worker slot.</dd>
+/* get the direct pointer to the memory associated with this worker slot */
+apr_status_t dptr(ap_slotmem_instance_t *s, unsigned int item_id, void **mem)
 
-      <dt>apr_status_t get(ap_slotmem_instance_t *s, unsigned int item_id, unsigned char *dest, apr_size_t dest_len)</dt>
-      <dd>get/read the memory from this slot to dest</dd>
+/* get/read the memory from this slot to dest */
+apr_status_t get(ap_slotmem_instance_t *s, unsigned int item_id, unsigned char *dest, apr_size_t dest_len)
 
-      <dt>apr_status_t put(ap_slotmem_instance_t *slot, unsigned int item_id, unsigned char *src, apr_size_t src_len)</dt>
-      <dd>put/write the data from src to this slot</dd>
+/* put/write the data from src to this slot */
+apr_status_t put(ap_slotmem_instance_t *slot, unsigned int item_id, unsigned char *src, apr_size_t src_len)
 
-      <dt>unsigned int num_slots(ap_slotmem_instance_t *s)</dt>
-      <dd>return the total number of slots in the segment</dd>
+/* return the total number of slots in the segment */
+unsigned int num_slots(ap_slotmem_instance_t *s)
 
-      <dt>apr_size_t slot_size(ap_slotmem_instance_t *s)</dt>
-      <dd>return the total data size, in bytes, of a slot in the segment</dd>
+/* return the total data size, in bytes, of a slot in the segment */
+apr_size_t slot_size(ap_slotmem_instance_t *s)
 
-      <dt>apr_status_t grab(ap_slotmem_instance_t *s, unsigned int *item_id);</dt>
-      <dd>grab or allocate the first free slot and mark as in-use (does not do any data copying)</dd>
+/* grab or allocate the first free slot and mark as in-use (does not do any data copying) */
+apr_status_t grab(ap_slotmem_instance_t *s, unsigned int *item_id)
 
-      <dt>apr_status_t fgrab(ap_slotmem_instance_t *s, unsigned int item_id);</dt>
-      <dd>forced grab or allocate the specified slot and mark as in-use (does not do any data copying)</dd>
+/* forced grab or allocate the specified slot and mark as in-use (does not do any data copying) */
+apr_status_t fgrab(ap_slotmem_instance_t *s, unsigned int item_id)
 
-      <dt>apr_status_t release(ap_slotmem_instance_t *s, unsigned int item_id);</dt>
-      <dd>release or free a slot and mark as not in-use (does not do any data copying)</dd>
-    </dl>
+/* release or free a slot and mark as not in-use (does not do any data copying) */
+apr_status_t release(ap_slotmem_instance_t *s, unsigned int item_id)
+</highlight>
 
 </summary>