cocoon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject cvs commit: xml-cocoon2/src/org/apache/cocoon/components/language/markup/sitemap/java sitemap.xsl
Date Thu, 21 Jun 2001 11:20:16 GMT
dims        01/06/21 04:20:16

  Modified:    src/org/apache/cocoon/components/language/markup/sitemap/java
                        sitemap.xsl
  Log:
  Patch for "sitemap redirections + target spec"
  from Christian Haul <haul@dvs1.informatik.tu-darmstadt.de>
  
  Revision  Changes    Path
  1.19      +11 -1     xml-cocoon2/src/org/apache/cocoon/components/language/markup/sitemap/java/sitemap.xsl
  
  Index: sitemap.xsl
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/components/language/markup/sitemap/java/sitemap.xsl,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -r1.18 -r1.19
  --- sitemap.xsl	2001/06/21 06:52:56	1.18
  +++ sitemap.xsl	2001/06/21 11:20:15	1.19
  @@ -127,7 +127,7 @@
        *
        * @author &lt;a href="mailto:giacomo@apache.org"&gt;Giacomo Pati&lt;/a&gt;
        * @author &lt;a href="mailto:bloritsch@apache.org"&gt;Berin Loritsch&lt;/a&gt;
  -     * @version CVS $Id: sitemap.xsl,v 1.18 2001/06/21 06:52:56 cziegeler Exp $
  +     * @version CVS $Id: sitemap.xsl,v 1.19 2001/06/21 11:20:15 dims Exp $
        */
       public class <xsl:value-of select="@file-name"/> extends AbstractSitemap {
         static final String LOCATION = "<xsl:value-of select="translate(@file-path, '/',
'.')"/>.<xsl:value-of select="@file-name"/>";
  @@ -1163,6 +1163,16 @@
   
         <!-- redirect to a internal resource definition -->
         <xsl:when test="@resource">
  +        <xsl:variable name="target">
  +          <xsl:call-template name="get-parameter">
  +            <xsl:with-param name="parname">target</xsl:with-param>
  +          </xsl:call-template>
  +        </xsl:variable>
  +        <xsl:if test="string-length($target) > 0 and string($target) != '&quot;&quot;'">
  +          map = new HashMap(1);
  +          map.put("target","<xsl:value-of select="$target"/>");
  +          listOfMaps.add(map);
  +        </xsl:if>
            Class[] argTypes = new Class[] {StreamPipeline.class, EventPipeline.class, List.class,
Environment.class, String.class, Boolean.TYPE};
            Object[] argValues = new Object[] {pipeline, eventPipeline, listOfMaps, environment,
cocoon_view, new Boolean(internalRequest)};
            String methodName = "resource_" + substitute(listOfMaps, "<xsl:value-of select="translate(@resource,
'- ', '__')"/>");
  
  
  

----------------------------------------------------------------------
In case of troubles, e-mail:     webmaster@xml.apache.org
To unsubscribe, e-mail:          cocoon-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: cocoon-cvs-help@xml.apache.org


Mime
View raw message