1<?xml version="1.0"?> 2<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> 3 4 <!-- FileName: namedtemplate13 --> 5 <!-- Document: http://www.w3.org/TR/xslt --> 6 <!-- DocVersion: 19991116 --> 7 <!-- Section: 11.6 --> 8 <!-- Creator: David Marston --> 9 <!-- Purpose: Ensure that we can use the default parameter value on some calls --> 10 11<xsl:template match="/doc"> 12 <out> 13 <xsl:text>Looking for doc...</xsl:text> 14 <xsl:choose> 15 <xsl:when test="//doc"> 16 <xsl:call-template name="status"> 17 <xsl:with-param name="X1">hasDocBelow</xsl:with-param> 18 </xsl:call-template> 19 </xsl:when> 20 <xsl:otherwise> 21 <xsl:call-template name="status"/> 22 </xsl:otherwise> 23 </xsl:choose> 24 <xsl:text>
Looking for croc...</xsl:text> 25 <xsl:choose> 26 <xsl:when test="//croc"> 27 <xsl:call-template name="status"> 28 <xsl:with-param name="X1">hasCrocBelow</xsl:with-param> 29 </xsl:call-template> 30 </xsl:when> 31 <xsl:otherwise> 32 <xsl:call-template name="status"/> 33 </xsl:otherwise> 34 </xsl:choose> 35 <xsl:text>
Looking for bloc...</xsl:text> 36 <xsl:choose> 37 <xsl:when test="//bloc"> 38 <xsl:call-template name="status"> 39 <xsl:with-param name="X1">hasBlocBelow</xsl:with-param> 40 </xsl:call-template> 41 </xsl:when> 42 <xsl:otherwise> 43 <xsl:call-template name="status"/> 44 </xsl:otherwise> 45 </xsl:choose> 46 </out> 47</xsl:template> 48 49<xsl:template name="status"> 50 <xsl:param name="X1">noLowerNode</xsl:param> 51 <xsl:text>X1=</xsl:text><xsl:value-of select="$X1"/> 52</xsl:template> 53 54 55 <!-- 56 * Licensed to the Apache Software Foundation (ASF) under one 57 * or more contributor license agreements. See the NOTICE file 58 * distributed with this work for additional information 59 * regarding copyright ownership. The ASF licenses this file 60 * to you under the Apache License, Version 2.0 (the "License"); 61 * you may not use this file except in compliance with the License. 62 * You may obtain a copy of the License at 63 * 64 * http://www.apache.org/licenses/LICENSE-2.0 65 * 66 * Unless required by applicable law or agreed to in writing, software 67 * distributed under the License is distributed on an "AS IS" BASIS, 68 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 69 * See the License for the specific language governing permissions and 70 * limitations under the License. 71 --> 72 73</xsl:stylesheet> 74