⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 htinit.h

📁 www工具包
💻 H
字号:
/*                                      W3C Sample Code Library libwww Default Initialization                              DEFAULT INITIALIZATION METHODS                                              *//***      (c) COPYRIGHT MIT 1995.**      Please first read the full copyright statement in the file COPYRIGH.*//*   As mentioned in the Library Architecture, libwww consists of a small core and a large   set of hooks for adding functionality. By itself, the core it not capable of performing   any Web related tasks like accessing a HTTP server or parsing a HTML document. All this   functionality must be registered by the application. This way, the core of libwww is   kept application independent and can be used as the basic building block for any kind   of Web application. The Library comes with a large set of default functions, for   example for accessing HTTP and FTP servers, parsing RFC 822 headers etc. This module   helps the application programmer setting up all this functionality, but it is important   to note that none of it is required in order to use the Library.      This module is implemented by HTInit.c, and it is a part of the W3C Sample Code   Library. You can also have a look at the other Initialization modules.    */#ifndef HTINIT_H#define HTINIT_H#include "WWWLib.h"#include "WWWApp.h"/*DEFAULT TRANSPORT PROTOCOL MODULES   Register the default set of transport protocols.    */#include "WWWTrans.h"extern void HTTransportInit (void);/*DEFAULT PROTOCOL MODULES   Set up default bindings between access schemes and the set of protocol modules in the   Library. The preemptive version registers all protocol modules to use blocking sockets.    */#include "WWWHTTP.h"#include "WWWFile.h"#include "WWWFTP.h"#include "WWWGophe.h"#include "WWWTelnt.h"#include "WWWNews.h"#ifdef HT_DIRECT_WAIS#include "WWWWAIS.h"#endif#ifndef FTP_PORT#define FTP_PORT        21#endif#ifndef NEWS_PORT#define NEWS_PORT       119#endif#ifndef GOPHER_PORT#define GOPHER_PORT     70#endif#ifndef WAIS_PORT#define WAIS_PORT       666#endif#ifndef HTTP_PORT#define HTTP_PORT       80#endif#define HTAccessInit    HTProtocolInitextern void HTProtocolInit (void);extern void HTProtocolPreemptiveInit (void);/*DEFAULT MIME PARSERS   The core doesn't have any built in MIME parsers, but many of the protocols need them.   For instance, many elements of the library rely on the Content-Length being correctly   set. HTMIMEInit() provides the minimal functionality needed for library reliabilty.    */#include "WWWMIME.h"#include "WWWApp.h"extern void HTMIMEInit (void);/*DEFAULT EVENT MANAGER   libwww core does not have any default event loop - it has to be added by the   application. However, it does come with an example implementation thta may be used.   This implementation is based on a select system call using non-blocking and interleaved   sockets.    */#include "WWWApp.h"/*DEFAULT MEDIA TYPE CONVERSIONS   The Converters are used to convert a media type to another media type, or to present it   on screen. This is a part of the stream stack algorithm. The Presenters are also used   in the stream stack, but are initialized separately.    */#include "WWWMIME.h"#include "WWWHTML.h"#include "WWWStream.h"#include "WWWDir.h"#include "WWWCache.h"#ifdef HT_EXPAT#include "WWWXML.h"#endifextern void HTConverterInit     (HTList * conversions);/*  Presenters     The Presenters are used to present a media type to the use by calling an external   program, for example a post script viewer. This is a part of the stream stack   algorithm. The Converters are also used in the stream stack, but are initialized   separately. The Presenters use the same include files as the Converters.    */extern void HTPresenterInit     (HTList * conversions);/*  Converters and Presenters     This function is only defined in order to preserve backward compatibility.    */extern void HTFormatInit        (HTList * conversions);/*DEFAULT TRANSFER ENCODINGS   Transfer encoders and decoders can handle encodings like chunked etc.    */#include "WWWHTTP.h"extern void HTTransferEncoderInit       (HTList * encodings);/*DEFAULT CONTENT ENCODINGS   Content encoders and decoders can handle encodings like deflate etc.    */#include "WWWZip.h"extern void HTContentEncoderInit        (HTList * encodings);/*DEFAULT BEFORE AND AFTER FILTERS   This module provides a set of default BEFORE and AFTER filters that can be registered   by the Net manager to be called before and after a request. All filters can be   registered either to be called globally (all requests) or locally (pr request basis).   Not done automaticly - may be done by application!     BEFORE Filters     The BEFORE filters handle proxies, caches, rule files etc. The filters are called in   the order by which the are registered    */#include "WWWApp.h"extern void HTBeforeInit (void);/*  AFTER Filters     The AFTER filters handle error messages, logging, redirection, authentication etc. The   filters are called in the order by which the are registered    */extern void HTAfterInit (void);/*  BEFORE and AFTER Filters     This is just a short cut for registrating both BEFORE and AFTER at once    */extern void HTNetInit (void);/*DEFAULT ACCESS AUTHENTICATION MODULES   The Access Manager which is implemented as a BEFORE and an AFTER filter (automatically   registered in HTNetInit()) does not by default know of any access authentication   schemes. As everything else, this must be registered! This function does the job and   should be all you need.    */extern void HTAAInit (void);/*DEFAULT MESSAGE AND DIALOG FUNCTIONS   We register a set of alert messages Not done automaticly - may be done by application!    */#include "WWWApp.h"extern void HTAlertInit (void);/*DEFAULT ICONS FOR DIRECTORY LISTINGS   The WWWDir interface contains support for including references (URLs and ALT text tags)   to icons in directory listings. The icons are selected as a function of the media type   and the content encoding of the file in question. That is - you can set up icons for   compressed files, postscript files etc. There is also a small set of specific icons   representing directories etc.    */#include "WWWFile.h"extern void HTIconInit (const char * url_prefix);/* */#endif/*      ___________________________________                               @(#) $Id: HTInit.html,v 2.53 1999/02/22 23:34:34 frystyk Exp $                                                                                             */

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -