W3C home > Mailing lists > Public > xproc-dev@w3.org > January 2010

RE: Optional xsl transformation

From: <Toman_Vojtech@emc.com>
Date: Thu, 7 Jan 2010 04:48:43 -0500
Message-ID: <997C307BEB90984EBE935699389EC41C78EB58@CORPUSMX70C.corp.emc.com>
To: <xproc-dev@w3.org>
With an XPath 2.0 XProc processor, I think you should be able to do
something like:

<p:choose>
  <p:when test="doc-available('style.xsl')">
    <p:xslt>...</p:xslt>
  </p:when>
  <p:otherwise>
    <p:identity>...</p:identity>
  </p:otherwise>
</p:choose>

In an XPath 1.0 implementation, you would probably need to resort to
p:load inside p:try to load the stylesheet or to something similar.

Regards,
Vojtech
Received on Thursday, 7 January 2010 09:49:40 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Thursday, 7 January 2010 09:49:41 GMT