File Generator
http://xml.apache.org/http://www.apache.org/http://www.w3.org/

Main
User Documentation

Generators
Overview

Default
File Generator

Core
Directory Generator
Fragment Extractor Generator
HTML Generator
Image Directory Generator
JSP Generator
Notifying Generator
Request Generator
Script Generator
Search Generator
Server Pages Generator
Status Generator
Stream Generator
Velocity Generator

Optional
PHP Generator
XML:DB Generator
XML:DB Collection Generator

File Generator

The file generator reads an xml document from the local file system or from any url. While url generator may appear to be a more suitable name, it's known as the file generator for historical reasons.

The file generator is the default generator.

  • Name : file
  • Class: org.apache.cocoon.generation.FileGenerator
  • Cacheable: yes - uses the last modification date of the xml document for validation.

The location of the source xml document is specified in the pipeline by the src attribute.

     
  <map:generate src="document.xml" type="file"/>
  <!-- The type attribute can be omitted as it is the default generator. -->
     

You can use an absolute filesystem pathname. See the explanation of file: URLs

Copyright © 1999-2002 The Apache Software Foundation. All Rights Reserved.