W3C home > Mailing lists > Public > public-qt-comments@w3.org > May 2007

[Bug 4523] Default Unprefixed Namespace Handling is Problematic

From: <bugzilla@wiggum.w3.org>
Date: Tue, 08 May 2007 18:03:03 +0000
CC:
To: public-qt-comments@w3.org
Message-Id: <E1HlU1f-0004Rw-QH@wiggum.w3.org>

http://www.w3.org/Bugs/Public/show_bug.cgi?id=4523





------- Comment #5 from Kenneth.B.Sall@saic.com  2007-05-08 18:03 -------
(In reply to comment #3)

I agree that usability is the main problem from my user viewpoint. Of the
potential solutions that Michael has offered below, I am most partial to option
(a) and secondarily to (b). For my needs, it would most useful if the scope is
the entire XQuery, as in option (a), but I can imagine how in other use cases
it may be desirable to switch the default namespace, such as in a specialized
local function, which makes option (b) or (c) appealing.

> From a usability point of view, I don't think you can expect people writing
> 1000-line queries to use the construct
> 
> *:bar[namespace-uri()='']
> 
> every time they want to refer to an element name in the source document.
> 
> I can think of a number of possible solutions:
> 
> (a) following XSLT 2.0, introduce a prolog declaration
> 
> declare default path namespace "zzzz";
> 
> indicating that an unprefixed element name in a Step is considered to be in
> namespace "zzzz", regardless of any other default namespace that might be in
> force
> 
> (b) introduce syntax that allows one to refer to an element in no namespace as
> distinct from an element in the default namespace, for example :foo or ~:foo
> 
> (c) introduce some capability to set the namespace context locally without
> constructing a new element, for example
> 
> with xmlns="" {
>   foo/bar
> }
> 
Received on Tuesday, 8 May 2007 18:03:05 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 16:57:18 UTC