# Libwww Architecture

The W3C Reference Library, a.k.a. Library of Common Code - or libwww, is a general code base written in portable C that can be used as a basis for building clients, servers and many other Web applications. It contains reference code for accessing HTTP, FTP, Gopher, News, WAIS, Telnet servers, and the local file system. Furthermore it provides modules for parsing, managing and presenting hypertext objects to the user and a wide spectra of generic programming utilities. The Library is the basis for many World-Wide Web applications and many W3C reference applications are built on top of it.

This document describes the architecture of the Library in generic terms without referring too much directly to the code itself. It is meant to give an overview of the design which is required if you intend to enhance the Library. If you are looking for a specific description of the API then please read the User's Guide.

This document is also available as one big HTML file intended for printout. Please note that not all links in this version work!

## Table of Contents

- Introduction
- Basic Design Model
- The Core
  - The Request Class
  - Post Web - a Generic Model for Posting on the Web
  - The Anchor Class
  - The Link Class
  - The User Profile Class
  - Threads and Event Loops
  - The Error Class
  - The Alert Class
  - File Suffix Binding
  - The Stream Class
  - Input and Output Streams
  - The Stream Pipe Manager
  - DNS Cache and Host Name Canonicalization
  - The Host Information Class
  - The Net Class
  - Befora an After Filters
  - The Transport Class
  - The Protocol Class
- Application Modules
  - The Cache Manager
  - Protocol Modules as State machines