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.1//EN" "document-v11.dtd">
- <document>
- <header>
- <title>Cocoon Source Resolving</title>
- <authors>
- <person name="Carsten Ziegeler" email="cziegeler@apache.org"/>
- </authors>
- </header>
- <body>
- <section>
- <title>Differences between Cocoon and Avalon Excalibur Source Resolving</title>
- <p>
- This story tries to list the changes between the two source resolving approaches.
- Originally, the source resolving was developed in the Cocoon community. As the
- community recognized that it had a more common value, the source resolving was
- donated to the Avalon Excalibur project and there it was refined and redesigned.
- Now the way back takes place by reintegrating the Avalon Excalibur Source Resolving
- into Cocoon and deprecating the now obsolete Cocoon Source Resolving.</p>
- <section>
- <title>The Interfaces</title>
- <p>
- Besides the package names the main difference is that the Cocoon Source object is
- XMLizable, that means it can directly send SAX events.
- The AE Source object is not XMLizable, which is more correct as a protocol only
- describes the way of transport but not the format of the data which is transfered.
- Therefore it provides a getMimeType() method.</p>
- </section>
- <section>
- <title>Caching</title>
- <p>
- The Cocoon Source object returns a last modified time stamp which is very limiting.
- For example a source could have an expires date or something like that.
- The AE Source returns a validity object which is capable of all these validity
- checkings. So the information used for validity checking is provided by the source
- object and not maintained by the client of the source as it is currently in Cocoon.</p>
- </section>
- <section>
- <title>XMLizable</title>
- <p>
- As we in Cocoonland are dealing a lot with XML, a Source implementation can still implement
- the XMLizable Interface (from AE and not from Cocoon!) to directly provide SAX events.
- The Cocoon SourceUtil class has a method toSAX() which gets a Source object and tests if
- it implements the XMLizable interface. If not the new AE XMLizer is used which is a
- component that can convert an input stream with a given mime-type to SAX events.
- This component is configurable and extensible.</p>
- </section>
- </section>
- </body>
- </document>
-