home *** CD-ROM | disk | FTP | other *** search
- <?xml version="1.0" encoding="UTF-8"?>
- <!--
- Copyright 1999-2004 The Apache Software Foundation
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
- -->
- <!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V1.0//EN" "document-v10.dtd">
-
- <document>
- <header>
- <title>Zip archive Serializer</title>
- <version>1.0</version>
- <type>Technical document</type>
- <authors>
- <person name="Sylvain Wallez" email="sylvain@apache.org"/>
- </authors>
- <abstract>This document describes the Zip archive serializer of Cocoon.</abstract>
- </header>
- <body>
- <s1 title="Zip archive Serializer">
- <p>The Zip archive serializer generates a zip archive by aggregating several sources.</p>
-
- <p>The input document should describe entries of the archive by means of
- their name (which can be a path) and their content either as URLs or
- inline data :</p>
- <ul>
- <li>URLs, given by the "src" attribute, are Cocoon sources and as such
- can use any of the protocols handled by Cocoon, including "cocoon:" to
- include dynamically generated content in the archive.</li>
- <li>inline data is represented by an XML document that is serialized to the
- zip entry using the serializer identified by the "serializer" attribute.</li>
- </ul>
- <p>
- Example :
- </p>
- <source>
- <zip:archive xmlns:zip="http://apache.org/cocoon/zip-archive/1.0">
- <zip:entry name="foo.html" src="cocoon://dynFoo.html"/>
- <zip:entry name="images/bar.jpeg" src="bar.jpeg"/>
- <zip:entry name="index.html" serializer="html">
- <html>
- <head>
- <title>Index page</title>
- </head>
- <body>
- Please go <a href="foo.html">there</a>
- </body>
- </html>
- </zip:entry>
- </zip:archive>
- </source>
-
- <ul>
- <li>Name: zip</li>
- <li>Class: org.apache.cocoon.serialization.ZipArchiveSerializer</li>
- <li>Cacheable: no</li>
- </ul>
- </s1>
- </body>
- </document>
-