moduleindex.xsl revision 66e48875fca2df6669dab4f2690ee36c6913c0ff
6fbd2e53c97ea6976d93e0ac521adabc55e0fb73nd Copyright 2002-2004 The Apache Software Foundation
beaad6ac31022179c44d88536811e9ccd9425696nd Licensed under the Apache License, Version 2.0 (the "License");
beaad6ac31022179c44d88536811e9ccd9425696nd you may not use this file except in compliance with the License.
beaad6ac31022179c44d88536811e9ccd9425696nd You may obtain a copy of the License at
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.
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- <moduleindex> -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- Builds the moduleindex page -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
66e48875fca2df6669dab4f2690ee36c6913c0ffnd [@id='corefeatures']" />
66e48875fca2df6669dab4f2690ee36c6913c0ffnd [@id='othermodules']" />
66e48875fca2df6669dab4f2690ee36c6913c0ffnd [@id='seealso']" />
66e48875fca2df6669dab4f2690ee36c6913c0ffnd [@id='corefeatures']" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <!-- core -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd [starts-with(., 'core.xml')])
7e68fce3cbd2246164e045a51ecd77f9f26680ednd select="document(modulefilelist/modulefile
7e68fce3cbd2246164e045a51ecd77f9f26680ednd [starts-with(., 'core.xml')])
7e68fce3cbd2246164e045a51ecd77f9f26680ednd select="document(modulefilelist/modulefile
7e68fce3cbd2246164e045a51ecd77f9f26680ednd [starts-with(., 'core.xml')])
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <!-- mpm_common -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd [starts-with(., 'mpm_common.xml')])
7e68fce3cbd2246164e045a51ecd77f9f26680ednd select="document(modulefilelist/modulefile
7e68fce3cbd2246164e045a51ecd77f9f26680ednd [starts-with(., 'mpm_common.xml')])
7e68fce3cbd2246164e045a51ecd77f9f26680ednd select="document(modulefilelist/modulefile
7e68fce3cbd2246164e045a51ecd77f9f26680ednd [starts-with(., 'mpm_common.xml')])
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <!-- and now the remaining MPMs -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd select="document(modulefilelist/modulefile)
7e68fce3cbd2246164e045a51ecd77f9f26680ednd /modulesynopsis
7e68fce3cbd2246164e045a51ecd77f9f26680ednd [status='MPM' and name != 'mpm_common']" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:sort select="substring-before(substring-after($translist,
7e68fce3cbd2246164e045a51ecd77f9f26680ednd concat('- ', translate(normalize-space(name), $lowercase,
7e68fce3cbd2246164e045a51ecd77f9f26680ednd $uppercase), ' ')), ' -')" />
66e48875fca2df6669dab4f2690ee36c6913c0ffnd [@id='othermodules']" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd select="document(modulefilelist/modulefile)
7e68fce3cbd2246164e045a51ecd77f9f26680ednd /modulesynopsis[status!='MPM' and
7e68fce3cbd2246164e045a51ecd77f9f26680ednd status!='Core']" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd select="$start-letters" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- /moduleindex -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- the working horse. builds list items of all modules starting with -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- one letter when done, it calls itself to catch the next letter -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<xsl:variable name="letter" select="substring($letters-todo, 1, 1)" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd select="$modules[$letter=substring(substring-before(substring-after(
7e68fce3cbd2246164e045a51ecd77f9f26680ednd $translist, concat('- ', translate(normalize-space(name), $lowercase,
7e68fce3cbd2246164e045a51ecd77f9f26680ednd $uppercase), ' ')), ' -'), 1, 1)]">
7e68fce3cbd2246164e045a51ecd77f9f26680ednd select="substring-before(substring-after($translist, concat('- ',
7e68fce3cbd2246164e045a51ecd77f9f26680ednd translate(normalize-space(name),$lowercase,$uppercase), ' ')), ' -')" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- call next letter, if there is -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd select="substring($letters-todo, 2)" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- /mindex-of-letter -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- collect start letters of modules -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd select="substring-before(substring-after($translist, concat('- ',
7e68fce3cbd2246164e045a51ecd77f9f26680ednd translate(normalize-space(name), $lowercase, $uppercase), ' ')),
7e68fce3cbd2246164e045a51ecd77f9f26680ednd select="substring(substring-before(substring-after($translist,
7e68fce3cbd2246164e045a51ecd77f9f26680ednd concat('- ', translate(normalize-space(name), $lowercase,
7e68fce3cbd2246164e045a51ecd77f9f26680ednd $uppercase), ' ')), ' -'), 1, 1)" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- /module-startletters -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- define module name translations for sorting -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- it's a kind of a hack... -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- we build a string that contains the following data: -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- "- modulename sortname - modulename sortname - ..." -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- (with all data in uppercase) -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- So, the translation from modulename to sortname can be done with the -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- expression below: -->
e0471b26427a7310358a7a3a835bd146072e4c29nd substring-before(
e0471b26427a7310358a7a3a835bd146072e4c29nd substring-after($translist,
7e68fce3cbd2246164e045a51ecd77f9f26680ednd concat('- ', translate(modulename,
7e68fce3cbd2246164e045a51ecd77f9f26680ednd $lowercase, $uppercase),
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- ==================================================================== -->
7e68fce3cbd2246164e045a51ecd77f9f26680ednd <xsl:variable name="sname" select="translate(normalize-space(name),
7e68fce3cbd2246164e045a51ecd77f9f26680ednd $lowercase, $uppercase)" />
7e68fce3cbd2246164e045a51ecd77f9f26680ednd<!-- /module-translist -->