Annotation of libwww/Library/src/WWWFile.html, revision 2.9

2.1       frystyk     1: <HTML>
                      2: <HEAD>
2.7       frystyk     3:   <TITLE>W3C Sample Code Library libwww Local File Access</TITLE>
2.1       frystyk     4: </HEAD>
                      5: <BODY>
2.6       frystyk     6: <H1>
2.7       frystyk     7:   Declaration of W3C Sample Code Local File Access
2.6       frystyk     8: </H1>
2.1       frystyk     9: <PRE>
                     10: /*
                     11: **     (c) COPYRIGHT MIT 1995.
                     12: **     Please first read the full copyright statement in the file COPYRIGH.
                     13: */
                     14: </PRE>
2.6       frystyk    15: <P>
                     16: This is the module for accessing local files and directories. The module
                     17: contans
2.1       frystyk    18: <PRE>
                     19: #ifndef WWWFILE_H
                     20: #define WWWFILE_H
                     21: </PRE>
                     22: <PRE>
                     23: #ifdef __cplusplus
                     24: extern "C" { 
                     25: #endif
                     26: </PRE>
2.6       frystyk    27: <H3>
                     28:   System dependencies
                     29: </H3>
                     30: <P>
2.8       frystyk    31: The <A HREF="wwwsys.html">wwwsys.h</A> file includes system-specific include
2.6       frystyk    32: files and flags for I/O to network and disk. The only reason for this file
                     33: is that the Internet world is more complicated than Posix and ANSI.
2.1       frystyk    34: <PRE>
2.8       frystyk    35: #include "wwwsys.h"
2.5       frystyk    36: </PRE>
2.6       frystyk    37: <H3>
                     38:   Access the Local File System
                     39: </H3>
                     40: <P>
                     41: The WWWFile interface provides a platform independent access scheme for local
                     42: files. The local file access works exactly like any other access scheme,
                     43: for example HTTP, in that the "file protocol" is independent of the underlying
                     44: transport. This can be used to for example slide in a CVS transport layser
                     45: underneath the file module without making any modifications to the file module
                     46: itself. You can read more about the transport managament in the
                     47: <A HREF="WWWTrans.html">Transport Interface</A>.
                     48: <PRE>#include "<A HREF="HTFile.html">HTFile.h</A>"
                     49: </PRE>
                     50: <H3>
                     51:   Content Negotiation
                     52: </H3>
                     53: <P>
                     54: When accessing the lccal file system, you can enable <I>content negotiation</I>
2.9     ! frystyk    55: as described in the <A HREF="http://www.w3.org/Protocols/">HTTP
2.6       frystyk    56: specification</A>. &nbsp;The content negotiation algorithm is based on file
                     57: suffixes as defined by the <A HREF="HTBind.html">Bind manager</A>. When looking
                     58: for a file you do <B>not</B> have to specify a suffix. Instead this module
                     59: looks for all alternatives with the same main name. For example, looking
                     60: for the file <I>Overview</I> can result in any of the files (or directories)
                     61: <I>Overview.txt</I>, <I>Overview.html</I>, <I>Overview.ps</I> etc. The selection
                     62: algorithm is based on the values of the preferences for language, media type,
                     63: encoding, etc. - exactly like a server would do with the <CODE>accept</CODE>
                     64: headers.
                     65: <PRE>#include "<A HREF="HTMulti.html">HTMulti.h</A>"
2.1       frystyk    66: </PRE>
2.6       frystyk    67: <P>
2.1       frystyk    68: End of FILE module
                     69: <PRE>
                     70: #ifdef __cplusplus
                     71: } /* end extern C definitions */
                     72: #endif
                     73: 
                     74: #endif
                     75: </PRE>
2.6       frystyk    76: <P>
                     77:   <HR>
2.4       frystyk    78: <ADDRESS>
2.9     ! frystyk    79:   @(#) $Id: WWWFile.html,v 2.8 1998/05/04 19:37:49 frystyk Exp $
2.4       frystyk    80: </ADDRESS>
2.6       frystyk    81: </BODY></HTML>

Webmaster