beaad6ac31022179c44d88536811e9ccd9425696nd<?xml version="1.0"?>
beaad6ac31022179c44d88536811e9ccd9425696nd
beaad6ac31022179c44d88536811e9ccd9425696nd<!--
db878466c5e95073429dda0bdd001f45e9486e16fielding Licensed to the Apache Software Foundation (ASF) under one or more
db878466c5e95073429dda0bdd001f45e9486e16fielding contributor license agreements. See the NOTICE file distributed with
db878466c5e95073429dda0bdd001f45e9486e16fielding this work for additional information regarding copyright ownership.
db878466c5e95073429dda0bdd001f45e9486e16fielding The ASF licenses this file to You under the Apache License, Version 2.0
db878466c5e95073429dda0bdd001f45e9486e16fielding (the "License"); you may not use this file except in compliance with
db878466c5e95073429dda0bdd001f45e9486e16fielding the License. You may obtain a copy of the License at
beaad6ac31022179c44d88536811e9ccd9425696nd
beaad6ac31022179c44d88536811e9ccd9425696nd http://www.apache.org/licenses/LICENSE-2.0
beaad6ac31022179c44d88536811e9ccd9425696nd
beaad6ac31022179c44d88536811e9ccd9425696nd Unless required by applicable law or agreed to in writing, software
beaad6ac31022179c44d88536811e9ccd9425696nd distributed under the License is distributed on an "AS IS" BASIS,
beaad6ac31022179c44d88536811e9ccd9425696nd WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
beaad6ac31022179c44d88536811e9ccd9425696nd See the License for the specific language governing permissions and
beaad6ac31022179c44d88536811e9ccd9425696nd limitations under the License.
beaad6ac31022179c44d88536811e9ccd9425696nd-->
beaad6ac31022179c44d88536811e9ccd9425696nd
01c674544bd4c211141bcd9fb09b96ffc18c6c3dnd<!DOCTYPE xsl:stylesheet [
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <!ENTITY lf SYSTEM "util/lf.xml">
01c674544bd4c211141bcd9fb09b96ffc18c6c3dnd]>
3726777f47ac4bba3e21b075905959bbea47e72eerikabele<xsl:stylesheet version="1.0"
3726777f47ac4bba3e21b075905959bbea47e72eerikabele xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
3726777f47ac4bba3e21b075905959bbea47e72eerikabele xmlns="http://www.w3.org/1999/xhtml">
3726777f47ac4bba3e21b075905959bbea47e72eerikabele
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- <directiveindex> -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- Builds the directive index page -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:template match="directiveindex">
66e48875fca2df6669dab4f2690ee36c6913c0ffnd<html xml:lang="{$doclang}" lang="{$doclang}">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:call-template name="head"/>&lf;
3726777f47ac4bba3e21b075905959bbea47e72eerikabele
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <body id="directive-index">
3726777f47ac4bba3e21b075905959bbea47e72eerikabele <xsl:call-template name="top"/>
3726777f47ac4bba3e21b075905959bbea47e72eerikabele
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:variable name="directives"
a32843995c13450ba9433b733242977cb4970265nd select="document(
a32843995c13450ba9433b733242977cb4970265nd document(document(document(
a32843995c13450ba9433b733242977cb4970265nd $allmodules)/modulefilelist/modulefile
a32843995c13450ba9433b733242977cb4970265nd )/*/@metafile)
a32843995c13450ba9433b733242977cb4970265nd /metafile/@reference
a32843995c13450ba9433b733242977cb4970265nd )
a32843995c13450ba9433b733242977cb4970265nd /modulesynopsis[status!='Obsolete']
a32843995c13450ba9433b733242977cb4970265nd /directivesynopsis[not(@location)]" />
8a72c24379e10c3f3d0dfe352bf15e45ee65c179nd
a8571599bf3a6921cc0b9f609009e4ec1f59e1d0nd <!-- collect the start letters -->
a8571599bf3a6921cc0b9f609009e4ec1f59e1d0nd <xsl:variable name="start-letters">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:call-template name="directive-startletters">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:with-param name="directives" select="$directives" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:call-template>
a8571599bf3a6921cc0b9f609009e4ec1f59e1d0nd </xsl:variable>
a8571599bf3a6921cc0b9f609009e4ec1f59e1d0nd
f1110149b5b6c28ecc39d1958d98ad9cfa8e41f3nd <xsl:call-template name="retired" />
f1110149b5b6c28ecc39d1958d98ad9cfa8e41f3nd
3726777f47ac4bba3e21b075905959bbea47e72eerikabele <div id="preamble">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <h1>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:value-of select="title" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </h1>&lf;
3726777f47ac4bba3e21b075905959bbea47e72eerikabele
8cfbcde8e416fd60132dd4324c42a5098da156cfnd <xsl:call-template name="langavail" />&lf;
8cfbcde8e416fd60132dd4324c42a5098da156cfnd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:apply-templates select="summary" />&lf;
3726777f47ac4bba3e21b075905959bbea47e72eerikabele
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <!-- letter bar -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <p class="letters">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:call-template name="letter-bar">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:with-param name="letters" select="$start-letters" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:with-param name="first" select="true()" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:call-template>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </p>&lf; <!-- /.letters -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </div>&lf; <!-- /preamble -->
d3cd98e7839dd1c737c18d42a916ed20860a50e1nd
3726777f47ac4bba3e21b075905959bbea47e72eerikabele <div id="directive-list">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <ul>&lf;
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:call-template name="dindex-of-letter">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:with-param name="letters-todo"
7e68fce3cbd2246164e045a51ecd77f9f26680ednd select="$start-letters" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:with-param name="directives" select="$directives" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:call-template>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </ul>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </div>&lf; <!-- /#directive-list -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:call-template name="bottom" />&lf;
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </body>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</html>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</xsl:template>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- /directiveindex -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- the working horse. builds list items of all directives starting with -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- one letter when done, it calls itself to catch the next letter -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:template name="dindex-of-letter">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:param name="letters-todo" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:param name="directives" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:variable name="letter" select="substring($letters-todo, 1, 1)"/>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:for-each
7e68fce3cbd2246164e045a51ecd77f9f26680ednd select="$directives
7e68fce3cbd2246164e045a51ecd77f9f26680ednd [$letter = translate(substring(normalize-space(name), 1, 1),
7e68fce3cbd2246164e045a51ecd77f9f26680ednd $lowercase, $uppercase)]">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:sort select="name" />
0a9fa0a3fe43e6ceb8064559e20ad1592dc2f1b4nd<xsl:sort select="/name" /> <!-- in case of duplicate directives -->
0a9fa0a3fe43e6ceb8064559e20ad1592dc2f1b4nd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <li>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <a href="{/name}.html#{translate(name, $uppercase, $lowercase)}">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:if test="position() = 1">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:attribute name="id">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:value-of select="$letter" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:attribute>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:attribute name="name">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:value-of select="$letter" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:attribute>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:if>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:if test="@type = 'section'">&lt;</xsl:if>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:value-of select="name" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:if test="@type = 'section'">&gt;</xsl:if>
480bee29abcc415b6b8c18d2ecbf2c5f88f1f05bnd </a>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </li>&lf;
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</xsl:for-each>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- call next letter, if there is -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:if test="string-length($letters-todo) &gt; 1">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:call-template name="dindex-of-letter">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:with-param name="letters-todo"
7e68fce3cbd2246164e045a51ecd77f9f26680ednd select="substring($letters-todo, 2)" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:with-param name="directives" select="$directives" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd </xsl:call-template>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</xsl:if>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd
7e68fce3cbd2246164e045a51ecd77f9f26680ednd</xsl:template>
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- /dindex-of-letter -->
3726777f47ac4bba3e21b075905959bbea47e72eerikabele
3726777f47ac4bba3e21b075905959bbea47e72eerikabele</xsl:stylesheet>