VirtualBox

Changeset 56586 in vbox


Ignore:
Timestamp:
Jun 22, 2015 6:49:22 PM (9 years ago)
Author:
vboxsync
Message:

change check.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/doc/manual/docbook-refentry-to-C-help.xsl

    r56571 r56586  
    334334
    335335  <xsl:template match="varlistentry/listitem">
    336     <xsl:if test="*[not(self::para or self::itemizedlist or self::orderedlist)]|text()">
    337       <xsl:message terminate="yes">
    338         <xsl:call-template name="get-node-path"/>: error: Expected varlistentry/listitem to only contain para, itemizedlist and orderedlist elements:
    339         <xsl:call-template name="list-nodes">
    340           <xsl:with-param name="Nodes" select="*[not(self::para or self::itemizedlist or self::orderedlist)]|text()"/>
    341         </xsl:call-template>
    342       </xsl:message>
    343     </xsl:if>
     336    <xsl:call-template name="check-children">
     337      <xsl:with-param name="UnsupportedNodes" select="*[not(self::para or self::itemizedlist or self::orderedlist)]|text()"/>
     338      <xsl:with-param name="SupportedNames">para, itemizedlist and orderedlist</xsl:with-param>
     339    </xsl:call-template>
    344340
    345341    <xsl:apply-templates select="*"/>
     
    861857  </xsl:template>
    862858
     859  <xsl:template name="check-children">
     860    <xsl:param name="Node"             select="."/>
     861    <xsl:param name="UnsupportedNodes" select="*"/>
     862    <xsl:param name="SupportedNames"   select="'none'"/>
     863    <xsl:if test="count($UnsupportedNodes) != 0">
     864      <xsl:message terminate="yes">
     865        <xsl:call-template name="get-node-path">
     866          <xsl:with-param name="Node" select="$Node"/>
     867        </xsl:call-template>
     868        <!-- -->: error: Only <xsl:value-of select="$SupportedNames"/> are supported as children to <!-- -->
     869        <xsl:value-of select="name($Node)"/>
     870        <!-- -->Unsupported children: <!-- -->
     871        <xsl:call-template name="list-nodes">
     872          <xsl:with-param name="Nodes" select="$UnsupportedNodes"/>
     873        </xsl:call-template>
     874      </xsl:message>
     875    </xsl:if>
     876  </xsl:template>
     877
    863878</xsl:stylesheet>
    864879
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette