HST's take on Richard Tobin's conditional proposal

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Wrt the discussion just now about conditionals, here's a pair of
pseudo-pipeline-documents which condition processing on a property of
the input (1) or of a computed stylesheet (2).  The 'otherwise'
branches aren't filled in, as we didn't discuss them. . .

1)
<pipe>
 <subpipe input="foo.xsl" output="#computedStyle">
  <step operation="XSLT 2.0" stylesheet="baz.xsl"/>
  <step operation="xxx" arg="yyy.xml"/>
 </subpipe>
 <subpipe input="#STDIN" output="#primary">
  <step operation="qqq" arg="rrr.xml"/>
 </subpipe>
 <subpipe input="#primary" output="#STDOUT">
  <choose>
   <when test="/doc/author/initials='ndw'">
    <subpipe input="#primary">
     <step operation="XSLT 2.0" stylesheet="#computedStyle"/>
    </subpipe>
   </when>
   <otherwise>
    ???
   </otherwise>
  </choose>
 </subpipe>
</pipe>

2)
<pipe>
 <subpipe input="foo.xsl" output="#computedStyle">
  <step operation="XSLT 2.0" stylesheet="baz.xsl"/>
  <step operation="xxx" arg="yyy.xml"/>
 </subpipe>
 <subpipe input="#STDIN" output="#primary">
  <step operation="qqq" arg="rrr.xml"/>
 </subpipe>
 <subpipe input="#computedStyle" output="#STDOUT">
  <choose>
   <when test="/xsl:stylesheet//fo:*">
    <subpipe input="#primary">
     <step operation="XSLT 2.0" stylesheet="#computedStyle"/>
    </subpipe>
   </when>
   <otherwise>
    ???
   </otherwise>
  </choose>
 </subpipe>
</pipe>

ht
- -- 
 Henry S. Thompson, HCRC Language Technology Group, University of Edinburgh
                     Half-time member of W3C Team
    2 Buccleuch Place, Edinburgh EH8 9LW, SCOTLAND -- (44) 131 650-4440
            Fax: (44) 131 650-4587, e-mail: ht@inf.ed.ac.uk
                   URL: http://www.ltg.ed.ac.uk/~ht/
[mail really from me _always_ has this .sig -- mail without it is forged spam]
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.6 (GNU/Linux)

iD8DBQFEGZnSkjnJixAXWBoRAu49AJ9I4qneX/vcxUFhg/SiLjZkhpNejQCfW6FK
EhXmWyZGmxNBa4QwOkvBPzk=
=HfPN
-----END PGP SIGNATURE-----

Received on Thursday, 16 March 2006 17:01:28 UTC