Annotation of libwww/Library/src/HTInit.html, revision 2.37

2.6       timbl       1: <HTML>
                      2: <HEAD>
2.36      frystyk     3:   <TITLE>W3C Reference Library libwww Default Initialization</TITLE>
2.6       timbl       4: </HEAD>
                      5: <BODY>
2.36      frystyk     6: <H1>
                      7:   Default Initialization Methods
                      8: </H1>
2.11      frystyk     9: <PRE>
                     10: /*
2.16      frystyk    11: **     (c) COPYRIGHT MIT 1995.
2.11      frystyk    12: **     Please first read the full copyright statement in the file COPYRIGH.
                     13: */
                     14: </PRE>
2.36      frystyk    15: <P>
                     16: As mentioned in the <A HREF="../User/Architecture/">Library Architecture</A>,
                     17: libwww consists of a small core and a large set of hooks for adding
                     18: functionality. By itself, the core it not capable of performing any Web related
                     19: tasks like accessing a HTTP server or parsing a HTML document. All this
                     20: functionality must be registered by the application. This way, the core of
                     21: libwww is kept application independent and can be used as the basic building
                     22: block for any kind of Web application. The Library comes with a large set
                     23: of default functions, for example for accessing HTTP and FTP servers, parsing
                     24: <A HREF="http://info.internet.isi.edu:80/in-notes/rfc/files/rfc822.txt">RFC
                     25: 822</A> headers etc. This module helps the application programmer setting
                     26: up all this functionality, but it is important to note that none of it is
                     27: <I>required</I> in order to use the Library.
                     28: <P>
                     29: This module is implemented by <A HREF="HTInit.c">HTInit.c</A>, and it is
                     30: a part of the <A HREF="http://www.w3.org/pub/WWW/Library/">W3C Reference
                     31: Library</A>. You can also have a look at the other
                     32: <A HREF="WWWInit.html">Initialization modules</A>.
2.9       frystyk    33: <PRE>
2.13      frystyk    34: #ifndef HTINIT_H
                     35: #define HTINIT_H
2.27      frystyk    36: #include "WWWLib.h"
2.37    ! eric       37: #include "WWWApp.h"
2.9       frystyk    38: </PRE>
2.36      frystyk    39: <H2>
                     40:   Default Transport Protocol Modules
                     41: </H2>
                     42: <P>
2.32      frystyk    43: Register the default set of transport protocols.
                     44: <PRE>
2.36      frystyk    45: #include "WWWTrans.h"
2.32      frystyk    46: 
                     47: extern void HTTransportInit (void);
                     48: </PRE>
2.36      frystyk    49: <H2>
                     50:   Default Protocol Modules
                     51: </H2>
                     52: <P>
                     53: Set up default bindings between access schemes and the set of protocol modules
                     54: in the Library.
2.32      frystyk    55: <PRE>
                     56: #include "WWWHTTP.h"
                     57: #include "WWWFile.h"
                     58: #include "WWWFTP.h"
                     59: #include "WWWGophe.h"
                     60: #include "WWWTelnt.h"
                     61: #include "WWWNews.h"
                     62: 
                     63: #ifdef HT_DIRECT_WAIS
                     64: #include "WWWWAIS.h"
                     65: #endif
                     66: 
                     67: extern void HTAccessInit (void);
                     68: </PRE>
2.36      frystyk    69: <H2>
2.37    ! eric       70:   Default MIME Parsers
        !            71: </H2>
        !            72: <P>
        !            73: The core doesn't have any built in MIME parsers, but many of the protocols 
        !            74: need them. For instance, many elements of the library rely on the 
        !            75: Content-Length being correctly set. HTMIMEInit provides the minimal 
        !            76: functionality needed for library reliablilty.
        !            77: <PRE>
        !            78: extern void HTMIMEInit (void);
        !            79: </PRE>
        !            80: <H2>
2.36      frystyk    81:   Default Event Manager
                     82: </H2>
                     83: <P>
                     84: The event loop is used if you are using non-blocking sockets or want to use
                     85: real threads.
2.35      frystyk    86: <PRE>
2.37    ! eric       87: #include "HTEvntrg.h"
2.35      frystyk    88: </PRE>
2.36      frystyk    89: <H2>
                     90:   Default Media Type Conversions
                     91: </H2>
                     92: <P>
                     93: The <EM>Converters</EM> are used to convert a media type to another media
                     94: type, or to present it on screen. This is a part of the stream stack algorithm.
                     95: The Presenters are also used in the stream stack, but are initialized separately.
2.14      frystyk    96: <PRE>
2.23      frystyk    97: #include "HTML.h"                      /* Uses HTML/HText interface */
                     98: #include "HTPlain.h"                   /* Uses HTML/HText interface */
                     99: 
2.32      frystyk   100: #include "WWWMIME.h"
                    101: #include "WWWHTML.h"
                    102: #include "WWWStream.h"
                    103: #include "WWWDir.h"
                    104: #include "WWWRules.h"
2.23      frystyk   105: 
2.21      frystyk   106: extern void HTConverterInit    (HTList * conversions);
2.14      frystyk   107: </PRE>
2.36      frystyk   108: <H3>
                    109:   Presenters
                    110: </H3>
                    111: <P>
                    112: The <EM>Presenters</EM> are used to present a media type to the use by calling
                    113: an external program, for example a post script viewer. This is a part of
                    114: the stream stack algorithm. The <I>Converters</I> are also used in the stream
                    115: stack, but are initialized separately. The <I>Presenters</I> use the same
                    116: include files as the <I>Converters</I>.
2.14      frystyk   117: <PRE>
2.21      frystyk   118: extern void HTPresenterInit    (HTList * conversions);
2.14      frystyk   119: </PRE>
2.36      frystyk   120: <H3>
                    121:   Converters and Presenters
                    122: </H3>
                    123: <P>
                    124: This function is only defined in order to preserve backward compatibility.
2.21      frystyk   125: <PRE>
                    126: extern void HTFormatInit       (HTList * conversions);
2.9       frystyk   127: </PRE>
2.36      frystyk   128: <H2>
                    129:   Default Content and Transfer Encodings
                    130: </H2>
                    131: <P>
                    132: Content encoders and decoders can handle encodings like <EM>chunked</EM>
                    133: etc.
                    134: <PRE>#include "WWWHTTP.h"
2.9       frystyk   135: 
2.33      frystyk   136: extern void HTEncoderInit      (HTList * encodings);
                    137: </PRE>
2.36      frystyk   138: <H2>
                    139:   Default BEFORE and AFTER Net Callback Functions
                    140: </H2>
                    141: <P>
                    142: We register two often used callback functions: a BEFORE and a AFTER callback
                    143: Not done automaticly - may be done by application!
                    144: <PRE>#include "WWWApp.h"
2.33      frystyk   145: 
2.27      frystyk   146: extern void HTNetInit (void);
                    147: </PRE>
2.36      frystyk   148: <H2>
                    149:   Default Message and Dialog Functions
                    150: </H2>
                    151: <P>
                    152: We register a set of alert messages Not done automaticly - may be done by
                    153: application!
                    154: <PRE>#include "WWWApp.h"
2.27      frystyk   155: 
                    156: extern void HTAlertInit (void);
                    157: </PRE>
                    158: <PRE>
2.13      frystyk   159: #endif
2.9       frystyk   160: </PRE>
2.36      frystyk   161: <P>
                    162:   <HR>
2.31      frystyk   163: <ADDRESS>
2.37    ! eric      164:   @(#) $Id: HTInit.html,v 2.36 1996/05/20 15:06:51 frystyk Exp $
2.31      frystyk   165: </ADDRESS>
2.36      frystyk   166: </BODY></HTML>

Webmaster