dbertoni    02/05/09 17:11:40

  Modified:    c/samples/ExternalFunction foo.xsl
  Log:
  Added function-available() call.
  
  Revision  Changes    Path
  1.7       +12 -3     xml-xalan/c/samples/ExternalFunction/foo.xsl
  
  Index: foo.xsl
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/samples/ExternalFunction/foo.xsl,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- foo.xsl   20 Apr 2001 13:48:43 -0000      1.6
  +++ foo.xsl   10 May 2002 00:11:40 -0000      1.7
  @@ -26,9 +26,18 @@
     </xsl:template>
   
     <xsl:template match="now">       
  -    <when>
  -      Date and time when we figured all this out: <xsl:value-of 
select="external:asctime()"/>.
  -    </when>
  +    <xsl:choose>
  +       <xsl:when test="function-available('external:asctime')"> 
  +        <when>
  +          Date and time when we figured all this out: <xsl:value-of 
select="external:asctime()"/>.
  +        </when>
  +       </xsl:when>
  +       <xsl:otherwise>
  +        <result>
  +               The function external:asctime() is not available!
  +             </result>
  +       </xsl:otherwise>
  +    </xsl:choose>
     </xsl:template>
   
   </xsl:stylesheet>
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to