xsl-list
[Top] [All Lists]

Re: [xsl] statically known namespaces

2006-07-10 07:13:47
On Monday 10 July 2006 13:41, andrew welch wrote:
On 7/10/06, Florent Georges <darkman_spam(_at_)yahoo(_dot_)fr> wrote:
andrew welch wrote:

  Hi

I would have thought that XSLT 2.0 could benefit from having
"xsl" and "xs" predefined, any thoughts?

  Because an XSLT script is an XML document, I don't see any interest
in having the XSLT namespace already bound.  The XML Schema namespace
could be interesting, but IMHO not if it is the only one.

....ahh completely forgot the XML side of things, been reading XQuery
this morning.  The main point came from xs: though as my editor
doesn't auto-generate it, and as I've never committed it to memory I
have to cut and paste it each time...

It's certainly a nice feature of XQuery, and as "xs:" is only used in
attribute values it could be inbuilt and the stylesheet would still be
well-formed XML... but of course "xsl:" would still need defining so
there's not much point.

I agree the pre-defines makes writing queries easier.

I also sympathize with Nic James' comment on that one must have a rather well 
trained memory in order to create the boiler plate code in an XSL-T 
stylesheet without using a template. I think it heavily contributes to the 
verboseness and cumbersomeness of stylesheets. Perhaps a big plus for a 
programming language is "one must be able to write reasonable code without 
using a template." Well, the tradeoffs of XSL-T being XML is clear.

However, I know that some people disagree that XQuery predefines prefixes is a 
good thing. I didn't dwelve into their motivation, but it could be that some 
XQueries are valid XML except for not being namespace well-formed, and hence 
cause trouble. Don't ask me in what constellation.


Cheers,

                Frans

--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--