[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: Conditionally use attribute sets?

Subject: RE: Conditionally use attribute sets?
From: JBryant@xxxxxxxxx
Date: Mon, 14 Nov 2005 11:13:18 -0600
RE:  Conditionally use attribute sets?
> The entire choose block could be eliminated if attribute-sets were
> not restricted to QNames.  I would have thought runtime composition
> of these names was a natural place for version 2.0 to go, but it
> has not.
>
> I have always wanted to write this:
>
> <xsl:attribute name="xsl:use-attribute-sets" select="{$who}"/>

If the attribute should always be present, you could just write:

<bachelor xsl:use-attribute-sets="{$who}"/>

You'd only need to use a conditional block and an attribute instruction in 
cases where the attribute might not exist.

You could also create structures like this one:

<bachelor xsl:use-attribute-sets="{if ($who='') then 'Oscar' else $who}"/>

That's potentially very powerful stuff.

I'd be in favor of a change like that if it won't cause problems in some 
other context.

Jay Bryant
Bryant Communication Services
(presently consulting at Synergistic Solution Technologies)

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.