Annotation of libwww/Library/src/HTTP.html, revision 2.41

2.40      kahan       1: <HTML> 
2.6       timbl       2: <HEAD>
2.33      frystyk     3:   <!-- Changed by: Henrik Frystyk Nielsen, 17-May-1996 -->
2.36      frystyk     4:   <TITLE>W3C Sample Code Library libwww HTTP Client</TITLE>
2.13      frystyk     5: </HEAD>
2.6       timbl       6: <BODY>
2.33      frystyk     7: <H1>
                      8:   Multi Threaded HyperText Tranfer Protocol Client Module
                      9: </H1>
2.13      frystyk    10: <PRE>
                     11: /*
2.18      frystyk    12: **     (c) COPYRIGHT MIT 1995.
2.13      frystyk    13: **     Please first read the full copyright statement in the file COPYRIGH.
                     14: */
                     15: </PRE>
2.33      frystyk    16: <P>
2.35      frystyk    17: This is the HTTP client module. This is actually a very small definition
                     18: file as almost everything is set up elsewhere.
2.33      frystyk    19: <P>
                     20: This module is implemented by <A HREF="HTTP.c">HTTP.c</A>, and it is a part
2.38      frystyk    21: of the <A HREF="http://www.w3.org/Library/">W3C Sample Code Library</A>.
2.9       frystyk    22: <PRE>
                     23: #ifndef HTTP_H
2.1       timbl      24: #define HTTP_H
2.15      frystyk    25: 
2.34      frystyk    26: #include "HTProt.h"
2.26      frystyk    27: #include "HTStream.h"
2.41    ! vbancrof   28: 
        !            29: #ifdef __cplusplus
        !            30: extern "C" { 
        !            31: #endif 
2.35      frystyk    32: </PRE>
                     33: <H3>
                     34:   HTTP Client Connection Mode
                     35: </H3>
                     36: <P>
                     37: The HTTP client module supports various modes for communicating with HTTP
                     38: servers. The mode are defined by the enumeration below.
                     39: <PRE>
                     40: typedef enum _HTTPConnectionMode { 
2.37      frystyk    41:     HTTP_11_PIPELINING     = 0x1,
                     42:     HTTP_11_NO_PIPELINING  = 0x2, 
                     43:     HTTP_11_MUX            = 0x4,
                     44:     HTTP_FORCE_10          = 0x8
2.35      frystyk    45: } HTTPConnectionMode; 
2.9       frystyk    46: 
2.35      frystyk    47: extern void HTTP_setConnectionMode (HTTPConnectionMode mode);
                     48: extern HTTPConnectionMode HTTP_connectionMode (void);
                     49: </PRE>
                     50: <H3>
2.39      frystyk    51:   HTTP Write Delay of Content Bodies
                     52: </H3>
                     53: <P>
                     54: Because of the differences between HTTP/1.0 and HTTP/1.1, HTTP <TT>PUT</TT>
                     55: and <TT>POST</TT> requests can not be dealt with in non-preemptive mode -
                     56: they have to use timers and hence must be in preemptive mode.
                     57: <P>
                     58: The default write mechanism used is first to write the headers and then wait
                     59: for a period of time before writing the body. This often allows the server
                     60: to respond before we start sending data accross the wire. If the write for
                     61: some reason fails in a bad way then we try again, waiting a little bit longer
                     62: this time as this may give the server enough time to think.
                     63: <P>
                     64: The default wait periods are 2000ms for the first wait and 3000ms if that
                     65: fails. These are rather conservative values but can be changed by using these
                     66: functions. The second try value must be larger (or equal) to the first try
                     67: value and the first try value must be larger than 20 ms.
                     68: <PRE>extern BOOL HTTP_setBodyWriteDelay (ms_t first_try, ms_t second_try);
                     69: extern void HTTP_bodyWriteDelay (ms_t * first_try, ms_t * second_try);
                     70: </PRE>
                     71: <H3>
2.35      frystyk    72:   HTTP Event Handler
                     73: </H3>
                     74: <P>
                     75: The event handler is the actual HTTP client state machine taking care of
                     76: the communication.
                     77: <PRE>
2.34      frystyk    78: extern HTProtCallback HTLoadHTTP;
2.26      frystyk    79: extern HTConverter HTTPStatus_new;
2.10      frystyk    80: 
2.41    ! vbancrof   81: #ifdef __cplusplus
        !            82: }
        !            83: #endif
        !            84: 
2.6       timbl      85: #endif /* HTTP_H */
2.9       frystyk    86: </PRE>
2.33      frystyk    87: <P>
                     88:   <HR>
2.29      frystyk    89: <ADDRESS>
2.41    ! vbancrof   90:   @(#) $Id: HTTP.html,v 2.40 2000/02/29 16:34:15 kahan Exp $
2.29      frystyk    91: </ADDRESS>
2.33      frystyk    92: </BODY></HTML>

Webmaster