xref: /aosp_15_r20/external/apache-xml/test/tests/conf/namespace/namespace16.xsl (revision 1212f9a0ffdc28482b8821715d2222bf16dc14e2)
1<?xml version="1.0"?>
2<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
3        xmlns:help="http://foobar.com"
4        extension-element-prefixes="help">
5
6  <!-- FileName: namespace16 -->
7  <!-- Document: http://www.w3.org/TR/xpath -->
8  <!-- DocVersion: 19991116 -->
9  <!-- Section: 2.2 Stylesheet Element -->
10  <!-- Creator: Paul Dick -->
11  <!-- Purpose: XSLT processor must ignore a top-level element without giving
12        and error if it does not recognize the namespace URI. The prefix used
13        must still resolve to a URI; but that URI may not be known. -->
14
15<help:Header comment="Header would go here"/>
16<help:TOC comment="Table of Contents"/>
17<help:template comment="This is the main template" match="doc" process="children"/>
18
19<xsl:template match="doc">
20  <out>
21    <xsl:value-of select="'Testing '"/>
22    <xsl:for-each select="*">
23      <xsl:value-of select="."/><xsl:text> </xsl:text>
24    </xsl:for-each>
25    <xsl:call-template name="ThatTemp">
26      <xsl:with-param name="sam">quos</xsl:with-param>
27    </xsl:call-template>
28  </out>
29</xsl:template>
30
31<help:template comment="Named template" match="*" name="ThatTemp" process="children"/>
32
33<xsl:template name="ThatTemp">
34  <xsl:param name="sam">bo</xsl:param>
35  <xsl:copy-of select="$sam"/>
36</xsl:template>
37
38<help:Footer comment="Footer would go here"/>
39
40
41  <!--
42   * Licensed to the Apache Software Foundation (ASF) under one
43   * or more contributor license agreements. See the NOTICE file
44   * distributed with this work for additional information
45   * regarding copyright ownership. The ASF licenses this file
46   * to you under the Apache License, Version 2.0 (the  "License");
47   * you may not use this file except in compliance with the License.
48   * You may obtain a copy of the License at
49   *
50   *     http://www.apache.org/licenses/LICENSE-2.0
51   *
52   * Unless required by applicable law or agreed to in writing, software
53   * distributed under the License is distributed on an "AS IS" BASIS,
54   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
55   * See the License for the specific language governing permissions and
56   * limitations under the License.
57  -->
58
59</xsl:stylesheet>
60