Download Install Tutorial Docs FAQ Tools WikiLicense Team IRC Planet Involvement Shop Book

Changeset 701

Show
Ignore:
Timestamp:
10/02/05 21:09:10
Author:
fumanchu
Message:

Got rid of the itemizedlists in the apiref.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/docs/book/xml/apireference.xml

    r683 r701  
    77        <itemizedlist> 
    88            <listitem> 
    9                 <section> 
    10                     <title>cherrypy.threadData</title> 
    11                     <para>This attribute holds attributes that map to this thread only.</para> 
    12                 </section> 
     9                <title>cherrypy.threadData</title> 
     10                <para>This attribute holds attributes that map to this thread only.</para> 
    1311            </listitem> 
    1412        </itemizedlist> 
     
    1614    <section id="cherrypyrequest"> 
    1715        <title>cherrypy.request</title> 
    18         <itemizedlist> 
    19             <listitem> 
    20                 <section> 
    21                     <title>cherrypy.request.remoteAddr</title> 
    22                     <para>This attribute is a string containing the IP address of the client. It will 
    23                     be an empty string if it is not available.</para> 
    24                 </section> 
    25             </listitem> 
    26             <listitem> 
    27                 <section> 
    28                     <title>cherrypy.request.remotePort</title> 
    29                     <para>This attribute is an int containing the TCP port number of the client. It 
    30                     will be -1 if it is not available.</para> 
    31                 </section> 
    32             </listitem> 
    33             <listitem> 
    34                 <section> 
    35                     <title>cherrypy.request.remoteHost</title> 
    36                     <para>This attribute is a string containing the remote hostname of the 
    37                     client.</para> 
    38                 </section> 
    39             </listitem> 
    40             <listitem> 
    41                 <section> 
    42                     <title>cherrypy.request.headerMap</title> 
    43                     <para>This attribute is dictionary containing the received HTTP headers.</para> 
    44                 </section> 
    45             </listitem> 
    46             <listitem> 
    47                 <section> 
    48                     <title>cherrypy.request.requestLine</title> 
    49                     <para>This attribute is a string containing the first line of the raw HTTP 
    50                     request.</para> 
    51                 </section> 
    52             </listitem> 
    53             <listitem> 
    54                 <section> 
    55                     <title>cherrypy.request.simpleCookie</title> 
    56                     <para>This attribute is a SimpleCookie instance from the standard library's 
    57                     Cookie module which contains the incoming cookie values from the client.</para> 
    58                 </section> 
    59             </listitem> 
    60             <listitem> 
    61                 <section> 
    62                     <title>cherrypy.request.rfile</title> 
    63                     <para>This attribute is the input stream to the client. See 
    64                     cherrypy.request.processRequestBody for more information.</para> 
    65                 </section> 
    66             </listitem> 
    67             <listitem> 
    68                 <section> 
    69                     <title>cherrypy.request.processRequestBody</title> 
    70                     <para>This attribute should be accessed during the beforeRequestBody stage of the 
    71                     request (if you don't know what this means, read the section on filters). This 
    72                     specifies whether or not the request's POST data will be parsed into the 
    73                     cherrypy.request.paramMap. It defaults to true for POST requests, but when false, 
    74                     cherrypy.request.rfile will be readable by the exposed method. Otherwise, rfile 
    75                     is completely read before control is handled to the exposed method.</para> 
    76                 </section> 
    77             </listitem> 
    78             <listitem> 
    79                 <section> 
    80                     <title>cherrypy.request.method</title> 
    81                     <para>This attribute is a string containing the HTTP request method, such as GET 
    82                     or POST.</para> 
    83                 </section> 
    84             </listitem> 
    85             <listitem> 
    86                 <section> 
    87                     <title>cherrypy.request.protocol</title> 
    88                     <para>This attribute is a string containing the HTTP protocol of the request in 
    89                     the form of HTTP/x.x</para> 
    90                 </section> 
    91             </listitem> 
    92             <listitem> 
    93                 <section> 
    94                     <title>cherrypy.request.queryString</title> 
    95                     <para>This attribute is a string containing the query string of the request (the 
    96                     part of the URL following '?').</para> 
    97                 </section> 
    98             </listitem> 
    99             <listitem> 
    100                 <section> 
    101                     <title>cherrypy.request.path</title> 
    102                     <para>This attribute is a string containing the path of the resource the client 
    103                     requested.</para> 
    104                 </section> 
    105             </listitem> 
    106             <listitem> 
    107                 <section> 
    108                     <title>cherrypy.request.paramMap</title> 
    109                     <para>This attribute is a dictionary containing the query string and POST 
    110                     arguments of this request.</para> 
    111                 </section> 
    112             </listitem> 
    113             <listitem> 
    114                 <section> 
    115                     <title>cherrypy.request.base</title> 
    116                     <para>This attribute is a string containing the root URL of the server.</para> 
    117                 </section> 
    118             </listitem> 
    119             <listitem> 
    120                 <section> 
    121                     <title>cherrypy.request.browserUrl</title> 
    122                     <para>This attribute is a string containing the URL the client requested.</para> 
    123                 </section> 
    124             </listitem> 
    125             <listitem> 
    126                 <section> 
    127                     <title>cherrypy.request.objectPath</title> 
    128                     <para>This attribute is a string containing the path of the exposed method that 
    129                     will be called to handle this request. This is usually the same as 
    130                     cherrypy.request.path, but can be changed in a filter to change which method is 
    131                     actually called.</para> 
    132                 </section> 
    133             </listitem> 
    134             <listitem> 
    135                 <section> 
    136                     <title>cherrypy.request.originalPath</title> 
    137                     <para>This attribute is a string containing the original value of 
    138                     cherrypy.request.path, in case it is modified by a filter during the 
    139                     request.</para> 
    140                 </section> 
    141             </listitem> 
    142             <listitem> 
    143                 <section> 
    144                     <title>cherrypy.request.originalParamMap</title> 
    145                     <para>This attribute is a string containing the original value of 
    146                     cherrypy.request.paramMap, in case it is modified by a filter during the 
    147                     request.</para> 
    148                 </section> 
    149             </listitem> 
    150             <listitem> 
    151                 <section> 
    152                     <title>cherrypy.request.scheme</title> 
    153                     <para>This attribute is a string containing the URL scheme used in this request. 
    154                     It is either "http" or "https".</para> 
    155                 </section> 
    156             </listitem> 
    157         </itemizedlist> 
     16        <section> 
     17            <title>cherrypy.request.remoteAddr</title> 
     18            <para>This attribute is a string containing the IP address of the client. It will 
     19            be an empty string if it is not available.</para> 
     20        </section> 
     21        <section> 
     22            <title>cherrypy.request.remotePort</title> 
     23            <para>This attribute is an int containing the TCP port number of the client. It 
     24            will be -1 if it is not available.</para> 
     25        </section> 
     26        <section> 
     27            <title>cherrypy.request.remoteHost</title> 
     28            <para>This attribute is a string containing the remote hostname of the 
     29            client.</para> 
     30        </section> 
     31        <section> 
     32            <title>cherrypy.request.headerMap</title> 
     33            <para>This attribute is dictionary containing the received HTTP headers.</para> 
     34        </section> 
     35        <section> 
     36            <title>cherrypy.request.requestLine</title> 
     37            <para>This attribute is a string containing the first line of the raw HTTP 
     38            request.</para> 
     39        </section> 
     40        <section> 
     41            <title>cherrypy.request.simpleCookie</title> 
     42            <para>This attribute is a SimpleCookie instance from the standard library's 
     43            Cookie module which contains the incoming cookie values from the client.</para> 
     44        </section> 
     45        <section> 
     46            <title>cherrypy.request.rfile</title> 
     47            <para>This attribute is the input stream to the client. See 
     48            cherrypy.request.processRequestBody for more information.</para> 
     49        </section> 
     50        <section> 
     51            <title>cherrypy.request.processRequestBody</title> 
     52            <para>This attribute should be accessed during the beforeRequestBody stage of the 
     53            request (if you don't know what this means, read the section on filters). This 
     54            specifies whether or not the request's POST data will be parsed into the 
     55            cherrypy.request.paramMap. It defaults to true for POST requests, but when false, 
     56            cherrypy.request.rfile will be readable by the exposed method. Otherwise, rfile 
     57            is completely read before control is handled to the exposed method.</para> 
     58        </section> 
     59        <section> 
     60            <title>cherrypy.request.method</title> 
     61            <para>This attribute is a string containing the HTTP request method, such as GET 
     62            or POST.</para> 
     63        </section> 
     64        <section> 
     65            <title>cherrypy.request.protocol</title> 
     66            <para>This attribute is a string containing the HTTP protocol of the request in 
     67            the form of HTTP/x.x</para> 
     68        </section> 
     69        <section> 
     70            <title>cherrypy.request.queryString</title> 
     71            <para>This attribute is a string containing the query string of the request (the 
     72            part of the URL following '?').</para> 
     73        </section> 
     74        <section> 
     75            <title>cherrypy.request.path</title> 
     76            <para>This attribute is a string containing the path of the resource the client 
     77            requested.</para> 
     78        </section> 
     79        <section> 
     80            <title>cherrypy.request.paramMap</title> 
     81            <para>This attribute is a dictionary containing the query string and POST 
     82            arguments of this request.</para> 
     83        </section> 
     84        <section> 
     85            <title>cherrypy.request.base</title> 
     86            <para>This attribute is a string containing the root URL of the server.</para> 
     87        </section> 
     88        <section> 
     89            <title>cherrypy.request.browserUrl</title> 
     90            <para>This attribute is a string containing the URL the client requested.</para> 
     91        </section> 
     92        <section> 
     93            <title>cherrypy.request.objectPath</title> 
     94            <para>This attribute is a string containing the path of the exposed method that 
     95            will be called to handle this request. This is usually the same as 
     96            cherrypy.request.path, but can be changed in a filter to change which method is 
     97            actually called.</para> 
     98        </section> 
     99        <section> 
     100            <title>cherrypy.request.originalPath</title> 
     101            <para>This attribute is a string containing the original value of 
     102            cherrypy.request.path, in case it is modified by a filter during the 
     103            request.</para> 
     104        </section> 
     105        <section> 
     106            <title>cherrypy.request.originalParamMap</title> 
     107            <para>This attribute is a string containing the original value of 
     108            cherrypy.request.paramMap, in case it is modified by a filter during the 
     109            request.</para> 
     110        </section> 
     111        <section> 
     112            <title>cherrypy.request.scheme</title> 
     113            <para>This attribute is a string containing the URL scheme used in this request. 
     114            It is either "http" or "https".</para> 
     115        </section> 
    158116    </section> 
    159117    <!-- end cherrypy.request section --> 
    160118    <section id="cherrypyresponse"> 
    161119        <title>cherrypy.response</title> 
    162         <itemizedlist> 
    163             <listitem> 
    164                 <section> 
    165                     <title>cherrypy.response.headerMap</title> 
    166                     <para>This attribute is a dictionary with automatically titled keys. It holds all 
    167                     outgoing HTTP headers to the client.</para> 
    168                 </section> 
    169             </listitem> 
    170             <listitem> 
    171                 <section> 
    172                     <title>cherrypy.response.simpleCookie</title> 
    173                     <para>This attribute is a SimpleCookie instance from the standard library's 
    174                     Cookie module. It contains the outgoing cookie values.</para> 
    175                 </section> 
    176             </listitem> 
    177             <listitem> 
    178                 <section> 
    179                     <title>cherrypy.response.body</title> 
    180                     <para>This attribute is originally just the return value of the exposed method, 
    181                     but by the end of the request it must be an iterable (usually a list or generator 
    182                     of strings) which will be the content of the HTTP response.</para> 
    183                 </section> 
    184             </listitem> 
    185             <listitem> 
    186                 <section> 
    187                     <title>cherrypy.response.status</title> 
    188                     <para>This attribute is a string containing the HTTP response code in the form 
    189                     "### Reason Phrase", i.e. "200 OK"</para> 
    190                 </section> 
    191             </listitem> 
    192         </itemizedlist> 
     120        <section> 
     121            <title>cherrypy.response.headerMap</title> 
     122            <para>This attribute is a dictionary with automatically titled keys. It holds all 
     123            outgoing HTTP headers to the client.</para> 
     124        </section> 
     125        <section> 
     126            <title>cherrypy.response.simpleCookie</title> 
     127            <para>This attribute is a SimpleCookie instance from the standard library's 
     128            Cookie module. It contains the outgoing cookie values.</para> 
     129        </section> 
     130        <section> 
     131            <title>cherrypy.response.body</title> 
     132            <para>This attribute is originally just the return value of the exposed method, 
     133            but by the end of the request it must be an iterable (usually a list or generator 
     134            of strings) which will be the content of the HTTP response.</para> 
     135        </section> 
     136        <section> 
     137            <title>cherrypy.response.status</title> 
     138            <para>This attribute is a string containing the HTTP response code in the form 
     139            "### Reason Phrase", i.e. "200 OK"</para> 
     140        </section> 
    193141    </section> 
    194142    <section id="cherrypyserver"> 
    195143        <title>cherrypy.server</title> 
    196         <itemizedlist> 
    197             <listitem> 
    198                 <section> 
    199                     <title>cherrypy.server.start()</title> 
    200                     <para>Start the CherryPy Server.</para> 
    201                 </section> 
    202             </listitem> 
    203             <listitem> 
    204                 <section> 
    205                     <title>cherrypy.server.stop()</title> 
    206                     <para>Stop the CherryPy Server.</para> 
    207                 </section> 
    208             </listitem> 
    209             <listitem> 
    210                 <section> 
    211                     <title>cherrypy.server.restart()</title> 
    212                     <para>Restart the CherryPy Server.</para> 
    213                 </section> 
    214             </listitem> 
    215             <listitem> 
    216                 <section> 
    217                     <title>cherrypy.server.onStartServerList</title> 
    218                     <para>A list of functions that will be called when the server starts.</para> 
    219                 </section> 
    220             </listitem> 
    221             <listitem> 
    222                 <section> 
    223                     <title>cherrypy.server.onStopServerList</title> 
    224                     <para>A list of functions that will be called when the server stops.</para> 
    225                 </section> 
    226             </listitem> 
    227             <listitem> 
    228                 <section> 
    229                     <title>cherrypy.server.onStartThreadList</title> 
    230                     <para>A list of functions that will be called when each thread is started.</para> 
    231                 </section> 
    232             </listitem> 
    233             <listitem> 
    234                 <section> 
    235                     <title>cherrypy.server.onStopThreadList</title> 
    236                     <para>A list of functions that will be called when each thread is stopped.</para> 
    237                 </section> 
    238             </listitem> 
    239         </itemizedlist> 
     144        <section> 
     145            <title>cherrypy.server.start()</title> 
     146            <para>Start the CherryPy Server.</para> 
     147        </section> 
     148        <section> 
     149            <title>cherrypy.server.stop()</title> 
     150            <para>Stop the CherryPy Server.</para> 
     151        </section> 
     152        <section> 
     153            <title>cherrypy.server.restart()</title> 
     154            <para>Restart the CherryPy Server.</para> 
     155        </section> 
     156        <section> 
     157            <title>cherrypy.server.onStartServerList</title> 
     158            <para>A list of functions that will be called when the server starts.</para> 
     159        </section> 
     160        <section> 
     161            <title>cherrypy.server.onStopServerList</title> 
     162            <para>A list of functions that will be called when the server stops.</para> 
     163        </section> 
     164        <section> 
     165            <title>cherrypy.server.onStartThreadList</title> 
     166            <para>A list of functions that will be called when each thread is started.</para> 
     167        </section> 
     168        <section> 
     169            <title>cherrypy.server.onStopThreadList</title> 
     170            <para>A list of functions that will be called when each thread is stopped.</para> 
     171        </section> 
    240172    </section> 
    241173    <!-- end cherrypyserver section --> 
    242174    <section id="cherrypyconfig"> 
    243175        <title>cherrypy.config</title> 
    244         <itemizedlist> 
    245             <listitem> 
    246                 <section> 
    247                     <title>cherrypy.config.get(key, defaultValue = None, returnSection = 
    248                     False)</title> 
    249                     <para>This function returns the configuration value for the given key. The 
    250                     function checks if the setting is defined for the current request path, it walks 
    251                     up the request path until the key is found, or it returns the default value. If 
    252                     returnSection is True, the function returns the configuration path where the key 
    253                     is defined.</para> 
    254                 </section> 
    255             </listitem> 
    256             <listitem> 
    257                 <section> 
    258                     <title>cherrypy.config.getAll(key)</title> 
    259                     <para>The getAll function returns a list containing a (path, value) tuple for all 
    260                     occurences of the key within the request path. This function allows applications 
    261                     to inherit configuration data defined for parent paths.</para> 
    262                 </section> 
    263             </listitem> 
    264             <listitem> 
    265                 <section> 
    266                     <title>cherrypy.config.update(updateMap=None, file=None)</title> 
    267                     <para>Function to update the configuration map. upDateMap is a dictionary of the 
    268                     form {'sectionPath' : { } }, file is the path to the configuration file.</para> 
    269                 </section> 
    270             </listitem> 
    271         </itemizedlist> 
     176        <section> 
     177            <title>cherrypy.config.get(key, defaultValue = None, returnSection = 
     178            False)</title> 
     179            <para>This function returns the configuration value for the given key. The 
     180            function checks if the setting is defined for the current request path, it walks 
     181            up the request path until the key is found, or it returns the default value. If 
     182            returnSection is True, the function returns the configuration path where the key 
     183            is defined.</para> 
     184        </section> 
     185        <section> 
     186            <title>cherrypy.config.getAll(key)</title> 
     187            <para>The getAll function returns a list containing a (path, value) tuple for all 
     188            occurences of the key within the request path. This function allows applications 
     189            to inherit configuration data defined for parent paths.</para> 
     190        </section> 
     191        <section> 
     192            <title>cherrypy.config.update(updateMap=None, file=None)</title> 
     193            <para>Function to update the configuration map. upDateMap is a dictionary of the 
     194            form {'sectionPath' : { } }, file is the path to the configuration file.</para> 
     195        </section> 
    272196    </section> 
    273197    <section id="exceptions"> 
    274198        <title>cherrypy exceptions</title> 
    275         <itemizedlist> 
    276             <listitem> 
    277                 <section> 
    278                     <title>cherrypy.HTTPError</title> 
    279                     <para>This exception can be used to automatically send a response using a http 
    280                     status code, with an appropriate error page.</para> 
    281                 </section> 
    282             </listitem> 
    283             <listitem> 
    284                 <section><title>cherrypy.HTTPRedirect</title> This exception will force a HTTP 
    285                 redirect.</section> 
    286             </listitem> 
    287             <listitem> 
    288                 <section><title>cherrypy.NotFound</title> This exception is raised when CherryPy is 
    289                 unable to map a requested path to an internal method.</section> 
    290             </listitem> 
    291         </itemizedlist> 
     199        <section> 
     200            <title>cherrypy.HTTPError</title> 
     201            <para>This exception can be used to automatically send a response using a http 
     202            status code, with an appropriate error page.</para> 
     203        </section> 
     204        <section> 
     205            <title>cherrypy.HTTPRedirect</title> 
     206            <para>This exception will force a HTTP redirect.</para> 
     207        </section> 
     208        <section> 
     209            <title>cherrypy.NotFound</title> 
     210            <para>This exception is raised when CherryPy is unable to map a requested path to 
     211            an internal method.</para> 
     212        </section> 
     213        <section> 
     214            <title>cherrypy.InternalRedirect</title> 
     215            <para>This exception will redirect processing to another path within the site 
     216            (without informing the client).</para> 
     217        </section> 
    292218    </section> 
    293219    <section id="lib"> 
     
    295221        <section> 
    296222            <title>cherrypy.lib.cptools</title> 
    297             <itemizedlist
    298                 <section
    299                     <title>ExposeItems</title
    300                 </section> 
    301                 <section> 
    302                     <title>PositionalParametersAware</title> 
    303                 </section
    304             </itemizedlist
     223            <section
     224                <title>ExposeItems</title
     225                <para /
     226            </section> 
     227            <section> 
     228                <title>PositionalParametersAware</title> 
     229                <para /
     230            </section
    305231        </section> 
    306232    </section> 
    307233    <section id="specialfunctions"> 
    308234        <title>Special functions and attributes</title> 
    309         <itemizedlist> 
    310             <listitem> 
    311                 <section> 
    312                     <title>_cpOnError</title> 
    313                     <para>_cpOnError is a function for handling unanticipated exceptions, whether 
    314                     raised by CherryPy itself, or in user applications. The default simply raises 
    315                     HTTPError(500).</para> 
    316                 </section> 
    317             </listitem> 
    318             <listitem> 
    319                 <section> 
    320                     <title>_cpFilterList</title> 
    321                     <para>User defined filters are enabled using the class attribute _cpFilterList. 
    322                     Any filter instances placed in _cpFilterList will be applied to all methods of 
    323                     the class.</para> 
    324                 </section> 
    325             </listitem> 
    326         </itemizedlist> 
     235        <section> 
     236            <title>_cpOnError</title> 
     237            <para>_cpOnError is a function for handling unanticipated exceptions, whether 
     238            raised by CherryPy itself, or in user applications. The default simply raises 
     239            HTTPError(500).</para> 
     240        </section> 
     241        <section> 
     242            <title>_cpFilterList</title> 
     243            <para>User defined filters are enabled using the class attribute _cpFilterList. 
     244            Any filter instances placed in _cpFilterList will be applied to all methods of 
     245            the class.</para> 
     246        </section> 
    327247    </section> 
    328248    <section id="filters"> 
    329249        <title>Filter API</title> 
    330         <itemizedlist> 
    331             <listitem> 
    332                 <section> 
    333                     <title>onStartResource</title> 
    334                 </section> 
    335             </listitem> 
    336             <listitem> 
    337                 <section> 
    338                     <title>beforeRequestBody</title> 
    339                 </section> 
    340             </listitem> 
    341             <listitem> 
    342                 <section> 
    343                     <title>beforeMain</title> 
    344                 </section> 
    345             </listitem> 
    346             <listitem> 
    347                 <section> 
    348                     <title>beforeFinalize</title> 
    349                 </section> 
    350             </listitem> 
    351             <listitem> 
    352                 <section> 
    353                     <title>onEndResource</title> 
    354                 </section> 
    355             </listitem> 
    356             <listitem> 
    357                 <section> 
    358                     <title>beforeErrorResponse</title> 
    359                 </section> 
    360             </listitem> 
    361             <listitem> 
    362                 <section> 
    363                     <title>afterErrorResponse</title> 
    364                 </section> 
    365             </listitem> 
    366         </itemizedlist> 
     250        <section> 
     251            <title>onStartResource</title> 
     252        </section> 
     253        <section> 
     254            <title>beforeRequestBody</title> 
     255        </section> 
     256        <section> 
     257            <title>beforeMain</title> 
     258        </section> 
     259        <section> 
     260            <title>beforeFinalize</title> 
     261        </section> 
     262        <section> 
     263            <title>onEndResource</title> 
     264        </section> 
     265        <section> 
     266            <title>beforeErrorResponse</title> 
     267        </section> 
     268        <section> 
     269            <title>afterErrorResponse</title> 
     270        </section> 
    367271    </section> 
    368272</section> 

Hosted by WebFaction

Log in as guest/cpguest to create tickets