xref: /aosp_15_r20/external/apache-xml/test/tests/contrib/xsltc/mk/mk029.xsl (revision 1212f9a0ffdc28482b8821715d2222bf16dc14e2)
1<xsl:stylesheet version="1.0"
2     xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
3
4  <!-- Test FileName: mk030.xsl -->
5  <!-- Source Attribution:
6       This test was written by Michael Kay and is taken from
7       'XSLT Programmer's Reference' published by Wrox Press Limited in 2000;
8       ISBN 1-861003-12-9; copyright Wrox Press Limited 2000; all rights reserved.
9       Now updated in the second edition (ISBN 1861005067), http://www.wrox.com.
10       No part of this book may be reproduced, stored in a retrieval system or
11       transmitted in any form or by any means - electronic, electrostatic, mechanical,
12       photocopying, recording or otherwise - without the prior written permission of
13       the publisher, except in the case of brief quotations embodied in critical articles or reviews.
14  -->
15  <!-- Example: soloist.xml, soloist+index.xsl -->
16  <!-- Chapter/Page: 4-296 -->
17  <!-- Purpose: Using modes -->
18
19<xsl:import href="inc/soloist.xsl"/>
20
21<xsl:template match="/">
22<html><body>
23    <xsl:apply-templates/>
24    <table bgcolor="#cccccc" border="1" cellpadding="5">
25    <tr>
26        <td><b>Date</b></td>
27        <td><b>Venue</b></td>
28        <td><b>Composer</b></td>
29        <td><b>Work</b></td>
30        <td><b>Role</b></td>
31    </tr>
32    <xsl:apply-templates mode="index"/>
33    </table>
34</body></html>
35</xsl:template>
36
37<xsl:template match="performance" mode="index">
38    <tr>
39    <td><xsl:value-of select="date"/>&#xa0;</td>
40    <td><xsl:value-of select="venue"/>&#xa0;</td>
41    <td><xsl:value-of select="composer"/>&#xa0;</td>
42    <td><xsl:value-of select="work"/>&#xa0;</td>
43    <td><xsl:value-of select="role"/>&#xa0;</td>
44    </tr>
45</xsl:template>
46
47
48
49  <!--
50   * Licensed to the Apache Software Foundation (ASF) under one
51   * or more contributor license agreements. See the NOTICE file
52   * distributed with this work for additional information
53   * regarding copyright ownership. The ASF licenses this file
54   * to you under the Apache License, Version 2.0 (the  "License");
55   * you may not use this file except in compliance with the License.
56   * You may obtain a copy of the License at
57   *
58   *     http://www.apache.org/licenses/LICENSE-2.0
59   *
60   * Unless required by applicable law or agreed to in writing, software
61   * distributed under the License is distributed on an "AS IS" BASIS,
62   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
63   * See the License for the specific language governing permissions and
64   * limitations under the License.
65  -->
66
67</xsl:stylesheet>
68