Author: rgardler
Date: Mon Feb 26 15:34:15 2007
New Revision: 512076
URL: http://svn.apache.org/viewvc?view=rev&rev=512076
Log:
a step towards a generalised procesing framework - the idea is to be able to
provide any index by passing parameters from the request URI
Modified:
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/
(props changed)
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/input.xmap
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/resources/stylesheets/descriptorIndex-to-indexByCategory.xsl
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/resources/stylesheets/descriptorIndex-to-indexByLang.xsl
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/resources/stylesheets/locationmap-to-descriptorIndex.xsl
Propchange:
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Mon Feb 26 15:34:15 2007
@@ -0,0 +1 @@
+build
Modified:
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/input.xmap
URL:
http://svn.apache.org/viewvc/forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/input.xmap?view=diff&rev=512076&r1=512075&r2=512076
==============================================================================
---
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/input.xmap
(original)
+++
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/input.xmap
Mon Feb 26 15:34:15 2007
@@ -31,13 +31,6 @@
<cache-at-startup>true</cache-at-startup>
</map:transformer>
</map:transformers>
- <map:serializers default="html">
- <map:serializer name="rss091" mime-type="text/xml"
src="org.apache.cocoon.serialization.XMLSerializer">
- <doctype-public>-//Netscape Communications//DTD RSS
0.91//EN</doctype-public>
-
<doctype-system>http://my.netscape.com/publish/formats/rss-0.91.dtd</doctype-system>
- <encoding>ISO-8859-1</encoding>
- </map:serializer>
- </map:serializers>
<map:pipes>
<map:pipe name="navigation"
@@ -118,19 +111,19 @@
<map:match pattern="projectDetails/index/by*/*.xml">
<map:generate type="file"
src="cocoon:/projectDetails/descriptorIndex.xml" />
<map:transform src="{lm:doap.transform.descriptorIndex.indexBy{1}}">
- <map:parameter name="category" value="{2}"/>
+ <map:parameter name="filter" value="{2}"/>
</map:transform>
<map:transform src="{lm:transform.html.document}"/>
<map:serialize type="xml-document"/>
</map:match>
<map:match pattern="projectDetails/source.xml">
- <map:generate type="file" src="{lm:project.descriptor}" />
+ <map:generate type="file" src="{lm:doap.descriptor}" />
<map:serialize type="xml-document"/>
</map:match>
<map:match pattern="projectDetails/**.source.xml">
- <map:generate type="file" src="{lm:project.descriptor.{1}}" />
+ <map:generate type="file" src="{lm:doap.descriptor.{1}}" />
<map:serialize type="xml-document"/>
</map:match>
Modified:
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/resources/stylesheets/descriptorIndex-to-indexByCategory.xsl
URL:
http://svn.apache.org/viewvc/forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/resources/stylesheets/descriptorIndex-to-indexByCategory.xsl?view=diff&rev=512076&r1=512075&r2=512076
==============================================================================
---
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/resources/stylesheets/descriptorIndex-to-indexByCategory.xsl
(original)
+++
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/resources/stylesheets/descriptorIndex-to-indexByCategory.xsl
Mon Feb 26 15:34:15 2007
@@ -26,7 +26,7 @@
<xsl:key name="kDistinctCategory" match="doap:category" use="@rdf:resource"/>
- <xsl:param name="category"/>
+ <xsl:param name="filter"/>
<xsl:param
name="categoryURL">http://projects.apache.org/category/</xsl:param>
<xsl:template match="/">
@@ -36,10 +36,10 @@
</head>
<body>
<xsl:choose>
- <xsl:when test="$category">
+ <xsl:when test="$filter">
<section>
- <title>Index of projects in the category of <xsl:value-of
select="$category"/></title>
- <xsl:apply-templates
select="//descriptor[descendant::doap:category/@rdf:resource =
concat($categoryURL, $category)]"/>
+ <title>Index of projects in the category of <xsl:value-of
select="$filter"/></title>
+ <xsl:apply-templates
select="//descriptor[descendant::doap:category/@rdf:resource =
concat($categoryURL, $filter)]"/>
</section>
</xsl:when>
<xsl:otherwise>
@@ -47,7 +47,7 @@
<xsl:sort select="@rdf:resource"/>
<xsl:variable name="category" select="@rdf:resource"/>
<section>
- <title><xsl:value-of select="substring-after($category,
$categoryURL)"/></title>
+ <title><xsl:value-of select="substring-after($filter,
$categoryURL)"/></title>
<xsl:apply-templates
select="//descriptor[descendant::doap:[EMAIL PROTECTED]:resource =
$category]]"/>
</section>
</xsl:for-each>
Modified:
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/resources/stylesheets/descriptorIndex-to-indexByLang.xsl
URL:
http://svn.apache.org/viewvc/forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/resources/stylesheets/descriptorIndex-to-indexByLang.xsl?view=diff&rev=512076&r1=512075&r2=512076
==============================================================================
---
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/resources/stylesheets/descriptorIndex-to-indexByLang.xsl
(original)
+++
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/resources/stylesheets/descriptorIndex-to-indexByLang.xsl
Mon Feb 26 15:34:15 2007
@@ -26,7 +26,7 @@
<xsl:key name="kDistinctProgLang" match="doap:programming-language" use="."/>
- <xsl:param name="language"/>
+ <xsl:param name="filter"/>
<xsl:template match="/">
<html>
@@ -35,9 +35,9 @@
</head>
<body>
<xsl:choose>
- <xsl:when test="$language">
- <h1>Index of projects using <xsl:value-of select="$language"/></h1>
- <xsl:apply-templates
select="//descriptor[descendant::doap:programming-language = $language]"/>
+ <xsl:when test="$filter">
+ <h1>Index of projects using <xsl:value-of select="$filter"/></h1>
+ <xsl:apply-templates
select="//descriptor[descendant::doap:programming-language = $filter]"/>
</xsl:when>
<xsl:otherwise>
<xsl:for-each select="//doap:programming-language[generate-id() =
generate-id(key('kDistinctProgLang',.))]">
Modified:
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/resources/stylesheets/locationmap-to-descriptorIndex.xsl
URL:
http://svn.apache.org/viewvc/forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/resources/stylesheets/locationmap-to-descriptorIndex.xsl?view=diff&rev=512076&r1=512075&r2=512076
==============================================================================
---
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/resources/stylesheets/locationmap-to-descriptorIndex.xsl
(original)
+++
forrest/trunk/whiteboard/plugins/org.apache.forrest.plugin.input.doap/resources/stylesheets/locationmap-to-descriptorIndex.xsl
Mon Feb 26 15:34:15 2007
@@ -26,11 +26,11 @@
</descriptors>
</xsl:template>
- <xsl:template match="lm:locator/lm:match[starts-with(@pattern,
'project.descriptor')]">
+ <xsl:template match="lm:locator/lm:match[starts-with(@pattern,
'doap.descriptor')]">
<xsl:variable name="href-noext">
<xsl:choose>
- <xsl:when test="@pattern =
'project.descriptor'">/projectDetails</xsl:when>
- <xsl:otherwise><xsl:value-of select="substring-after(@pattern,
'project.descriptor.')"/></xsl:otherwise>
+ <xsl:when test="@pattern =
'doap.descriptor'">/projectDetails</xsl:when>
+ <xsl:otherwise><xsl:value-of select="substring-after(@pattern,
'doap.descriptor.')"/></xsl:otherwise>
</xsl:choose>
</xsl:variable>