-<map:match pattern="">
<map:generate src="samples.xml"/>
-<map:transform src="context://samples/common/style/xsl/html/simple-samples2html.xsl">
<map:parameter name="contextPath" value="{request:contextPath}"/>
</map:transform>
<map:serialize/>
</map:match>
-<!--
- News sources, post processed using XSLT, for content aggregation
- samples.
-->
-<map:match pattern="slashdot">
<map:generate src="http://slashdot.org/slashdot.xml"/>
<map:transform src="stylesheets/slashdot.xsl"/>
<map:serialize/>
</map:match>
-<map:match pattern="**.gif">
<map:read mime-type="image/gif" src="http://images.slashdot.org/topics/{1}.gif"/>
</map:match>
-<map:match pattern="**.jpg">
<map:read mime-type="image/jpg" src="http://images.slashdot.org/topics/{1}.jpg"/>
</map:match>
-<map:match pattern="moreover">
<map:generate src="http://www.moreover.com/cgi-local/page?o=xml&c=Developer%20news"/>
<map:transform src="stylesheets/moreover.xsl"/>
<map:serialize/>
</map:match>
-<map:match pattern="xmlhack">
<map:generate src="http://www.xmlhack.com/cdf.cdf"/>
<map:transform src="stylesheets/xmlhack.xsl"/>
<map:serialize/>
</map:match>
-<!--
- Content aggregation samples
-->
-<!-- Aggregation using the sitemap aggregator
-->
-<map:match pattern="aggregate">
-<map:aggregate element="page">
-<!--+
| Aggregation is a very powerful concept that allows a document
| be generated from several other documents. Strictly speaking,
| all parts are just concatenated in this order to a new
| document.
|
| Several things to note here:
|
| "cocoon:" is a pseudo protocol and refers to another
| pipeline. "cocoon:/" refers to a pipeline from the current
| sitemap while "cocoon://" refers to a pipeline from the root
| sitemap.
|
| Other pseudo protocols exist:
|
| "context:" is another pseudo protocol, "context://" is
| refering to a resource using the servlet context.
|
| "resource:" is yet another pseudo protocol, "resource://" is
| refering to a resource from the context classloader.
|
| All these pseudo protocols are declared in the cocoon.xconf.
|
| Thus, the parts refer to the pipeline fragments above.
|
| The optional element attribute places the content in a new root
| element named as specified, using the namespace provided by an
| optional ns attribute.
|
| Please see docs for further explanations.
+
-->
<map:part src="cocoon:/slashdot" element="slashdot"/>
<map:part src="cocoon:/moreover" element="moreover"/>
<map:part src="cocoon:/xmlhack" element="xmlhack"/>
</map:aggregate>
<map:transform src="stylesheets/news.xsl"/>
<map:serialize/>
</map:match>
-<!-- Aggregation using the include transformer
-->
-<map:match pattern="aggregate2">
<map:generate src="aggregate.xml"/>
<map:transform type="include"/>
<map:transform type="xsltc" src="stylesheets/news.xsl"/>
<map:serialize/>
</map:match>
-<!-- Aggregation using the include transformer, done in parallel threads
-->
-<map:match pattern="aggregate3">
<map:generate src="aggregate.xml"/>
-<map:transform type="include">
<map:parameter name="parallel" value="true"/>
</map:transform>
<map:transform type="xsltc" src="stylesheets/news.xsl"/>
<map:serialize/>
</map:match>
-<!-- Aggregation using the CInclude transformer
-->
-<map:match pattern="aggregate4">
<map:generate src="aggregate.xml"/>
<map:transform type="cinclude"/>
<map:transform type="xsltc" src="stylesheets/news.xsl"/>
<map:serialize/>
</map:match>
-<!-- Aggregation using the XInclude transformer
-->
-<map:match pattern="aggregate5">
<map:generate src="xaggregate.xml"/>
<map:transform type="xinclude"/>
<map:transform type="xsltc" src="stylesheets/news.xsl"/>
<map:serialize/>
</map:match>
-<!--
- Include Samples
-->
-<map:match pattern="include-*-*-*">
<map:generate src="content/i{3}.xml"/>
-<map:transform type="include">
<map:parameter name="parallel" value="{1}"/>
<map:parameter name="recursive" value="{2}"/>
</map:transform>
-<map:transform src="context://samples/common/style/xsl/html/simple-page2html.xsl">
<map:parameter name="contextPath" value="{request:contextPath}"/>
<map:parameter name="servletPath" value="{request:servletPath}"/>
<map:parameter name="sitemapURI" value="{request:sitemapURI}"/>
<map:parameter name="file" value="content/test.xml"/>
<map:parameter name="remove" value="{0}"/>
</map:transform>
<map:serialize/>
</map:match>
-<!--
- XInclude Samples
-->
-<map:match pattern="*.html">
<map:generate src="content/{1}.xml"/>
<map:transform type="xinclude"/>
-<map:transform src="context://samples/common/style/xsl/html/simple-page2html.xsl">
<map:parameter name="contextPath" value="{request:contextPath}"/>
<map:parameter name="servletPath" value="{request:servletPath}"/>
<map:parameter name="sitemapURI" value="{request:sitemapURI}"/>
<map:parameter name="file" value="content/test.xml"/>
<map:parameter name="remove" value="{0}"/>
</map:transform>
<map:serialize/>
</map:match>
-<!--
- COCOON-1985 Pipeline locking and parallel includes:
- Generating from cocoon source which includes self, in parallel threads, should not dead lock
-->
-<map:match pattern="lock">
<map:generate src="content/ilock.xml"/>
<map:serialize type="xml"/>
</map:match>
-<map:match pattern="include-lock">
<map:generate src="cocoon:/lock"/>
-<map:transform type="include">
<map:parameter name="parallel" value="true"/>
</map:transform>
-<map:transform src="context://samples/common/style/xsl/html/simple-page2html.xsl">
<map:parameter name="contextPath" value="{request:contextPath}"/>
<map:parameter name="servletPath" value="{request:servletPath}"/>
<map:parameter name="sitemapURI" value="{request:sitemapURI}"/>
<map:parameter name="file" value="content/ilock.xml"/>
<map:parameter name="remove" value="{0}"/>
</map:transform>
<map:serialize/>
</map:match>
-<map:match pattern="*.xml">
<map:generate src="content/{1}.xml"/>
<map:serialize/>
</map:match>
</map:pipeline>