OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   RE: [xml-dev] QNames in attribute values

[ Lists Home | Date Index | Thread Index ]

> Why must namespaces be restricted to only scoping element and
> attribute
> names? That seems to me to be unnecessarily restrictive.
> Other artifacts
> need name-scoping mechanisms, as well, and I don't see why we
> should force
> them to find another means of accomplishing this.

I think the problem is (a) that a document that uses QNames in content is
dependent on the namespace prefixes, and (b) that this dependency isn't
explicit. The result of this is that when a processor (e.g. an XSLT
processor) copies an element to a new place, it has to copy all the in-scope
namespace nodes, because it has no way of knowing which of the namespace
nodes are actually needed.

XSLT has an explicit mechanism, exclude-result-prefixes, to allow users to
declare that some of the in-scope namespaces for a literal result element in
the stylesheet are not needed in the result tree. There is no equivalent
mechanism to exclude namespaces when copying from the source tree.

Perhaps we need variant namespace declarations xmlNS="uri" and
xmlNS:prefix="uri" that declare namespaces that will only be used in element
and attribute names: this would mean these namespaces don't need to be
copied if they aren't needed, and it would mean the prefixes can safely be
changed when copying.

Mike Kay





 

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS