CSTUG

Stylesheet

<xsl:stylesheet version="1.0">

<!-- This stylesheet finds unknown authors, keywords and acronyms. -->
<xsl:import href="index.xsl"/> <xsl:import href="acro.xsl"/> <xsl:import href="auth.xsl"/> <xsl:import href="kwd.xsl"/> <xsl:include href="xinclude.xsl"/> <xsl:preserve-space elements="c:html c:text"/> <xsl:variable name="acromode">html</xsl:variable> <xsl:output method="text" indent="no"/> <xsl:strip-space elements="*"/> <xsl:template match="c:author"> <xsl:variable name="autid"> <xsl:value-of select="."/> </xsl:variable> <xsl:variable name="artid"> <xsl:value-of select="ancestor::node()[local-name()='article' and namespace-uri()='http://bulletin.cstug.cz/ns/CSTUGbulletin']/@id"/> </xsl:variable> <xsl:for-each select="$authorlist"> <xsl:if test="count(key('author', $autid)) = 0"> <xsl:text>No author </xsl:text> <xsl:value-of select="$autid"/> <xsl:text> in </xsl:text> <xsl:value-of select="$artid"/> <xsl:text/> </xsl:if> </xsl:for-each> </xsl:template> <xsl:template match="c:acro"> <xsl:variable name="acrid"> <xsl:value-of select="."/> </xsl:variable> <xsl:variable name="artid"> <xsl:value-of select="ancestor::node()[local-name()='article' and namespace-uri()='http://bulletin.cstug.cz/ns/CSTUGbulletin']/@id"/> </xsl:variable> <xsl:for-each select="$acronymlist"> <xsl:if test="count(key('acronym', $acrid)) = 0"> <xsl:text>No acronym </xsl:text> <xsl:value-of select="$acrid"/> <xsl:text> in </xsl:text> <xsl:value-of select="$artid"/> <xsl:text/> </xsl:if> </xsl:for-each> </xsl:template> <xsl:template match="c:keyword"> <xsl:variable name="kwdid"> <xsl:value-of select="."/> </xsl:variable> <xsl:variable name="artid"> <xsl:value-of select="ancestor::node()[local-name()='article' and namespace-uri()='http://bulletin.cstug.cz/ns/CSTUGbulletin']/@id"/> </xsl:variable> <xsl:for-each select="$keywordlist"> <xsl:if test="count(key('keyword', $kwdid)) = 0"> <xsl:text>No keyword </xsl:text> <xsl:value-of select="$kwdid"/> <xsl:text> in </xsl:text> <xsl:value-of select="$artid"/> <xsl:text/> </xsl:if> </xsl:for-each> </xsl:template> <xsl:template match="/" mode="xinclude"> <xsl:apply-templates/> </xsl:template> <xsl:template match="*"> <xsl:apply-templates/> </xsl:template> <xsl:template match="text()"/> </xsl:stylesheet>

unknown.xsl