- From: Jostein Austvik Jacobsen <josteinaj@gmail.com>
- Date: Wed, 9 Oct 2013 13:09:57 +0200
- To: XProc Dev <xproc-dev@w3.org>
- Message-ID: <CAOCxfQe2bLRxJrhjKU0zGKjHuo90ZzCWN2cE0Q-Z_Mhqobcp8A@mail.gmail.com>
Does this mean that the @kind attribute on ports would be removed? If there are no parameter ports, I guess you could still pass a <c:param-set/>-document to p:xslt (and any other step requiring parameters)? c:param-set would be the "first-class object" of sorts, and could be passed to a secondary port on p:xslt (which would default to an empty parameter set document). p:with-param would require you to always provide the port attribute, and it would be a dynamic error if the document on the referenced port is not a c:param-set. WDYT? Jostein On 9 October 2013 09:14, Toman, Vojtech <vojtech.toman@emc.com> wrote: > > Ok, then there are to things that are a drag about that: > > 1. That you have to declare the params at all. > > 2. That you have to provide a value to pass in. > > > > #2 seems to be the worse of the two. What if you have in your xslt: > > > > <xsl:param name="blah"> > > <xsl:choose> > > <!-- some logic here that only happens if nothing is passed in --> > > </xsl:choose> </xsl:param> > > > > Now you have to move that logic into the xpl as well? Or refactor the > > xslt so that you take in a dummy param and then test the dummy param > > and do the logic if it's not the default value? > > A good point. This could perhaps be solved/improved if we work on our > "unspecified optional option" story. For example, we might say that the > following works if $optional-option is not specified (param would remain > unspecified): > > <p:with-param name="param" select="$optional-option"/> > > Regards, > Vojtech > > -- > Vojtech Toman > Consultant Software Engineer > EMC | Information Intelligence Group > vojtech.toman@emc.com > http://developer.emc.com/xmltech > >
Received on Wednesday, 9 October 2013 11:10:45 UTC