[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Re: Re: mapping (Was: Re: Re: . in for)
Hi Dimitre, > I guess a similarity with '/' will lead to confusion only -- the > ***difference*** is bigger as '/' produces a node-set and not (any) > sequence. You could be right. Personally, I find it rather intuitive, precisely because it's similar to '/', but it might just be me. > Perhaps one would want to write something like this: > > $departments/(lower-case(.)) Well, yes, I did :), until Mike persuaded me it wasn't a good idea because: $departments/name/lower-case(.) would on occasion give surprisingly different results from: $departments/lower-case(name) It seemed a natural extension now that function calls, and even more complex expressions, are allowed as steps within path expressions as long as they return a node set. The path: $departments / key('students', student/@id) / if (@registered = false()) then name else () works, after all. (Just demonstrating the use of if in a general step - the same thing could be done more elegantly with a predicate instead.) Cheers, Jeni --- Jeni Tennison http://www.jenitennison.com/ XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|