cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joerg Heinicke <joerg.heini...@gmx.de>
Subject Re: Momento and Cocoon
Date Mon, 01 Mar 2004 19:59:40 GMT
On 26.02.2004 22:04, Alan wrote:

>>I would guess that Momento mainly would be accessed through the document 
>>function in XSLT and XQuery. Saxon use JAXP 1.1 as external API to the 
>>transformerand the URLs in the document functions are resolved by using 
>>an implementation of javax.xml.transform.URIResolver that is provided by 
>>the TraxTransformer.
> 
> 
> The above is somewhat confusing for me. Momento does support the
>     JAXP API. XUpdate is implemented as a SAX filter. It seems like
>     Momento would work nicely in as a source, sink, or filter for
>     SAX events.
>     
>     I've imagined that a pipeline would start with a Momento
>     document and an XSLT trasform or XQuery query.
> 
>     Something along these lines:
>     
>         <map:match pattern="index.html">
>           <map:generate type="momento" src="momento.mx"
>                                        xslt="index-document.xslt"/>
>           <map:transform type="xslt" src="document-to-web.xslt"/>
>           <map:serialize type="html"/>
>         </map:match>
> 
>     (It is easier for me to express myself as a Cocoon user.)

It was already mentioned and I only want to repeat it here: Momento 
should not be implemented as generator, but as source. As Momento 
returns also only XML just the file or xml generator should be needed. 
Example:

<map:generate src="momento:/document"/>

With the mentioned xmldb interface you would write the source just as 
the xindice source and use it like the following ("copied" from xindice 
sample sitemap):

<map:generate src="xmldb:momento://db/document#xpath"/>

The only thing I don't know exactly how to handle is XQuery. If it is 
used like XSLT we should add a XQueryTransformer later, but if the 
comparison to JXTemplate is more appropriate an XQueryGenerator would be 
needed (maybe both is useful).

Joerg

Mime
View raw message