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

Re: xmlns in the root element prevents transformation

Subject: Re: xmlns in the root element prevents transformation
From: "Liam R. E. Quin liam@xxxxxxxxxxxxxxxx" <xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx>
Date: Fri, 24 Jul 2020 16:30:19 -0000
Re:  xmlns in the root element prevents transformation
On Fri, 2020-07-24 at 15:17 +0000, BR Chrisman brchrisman@xxxxxxxxx
wrote:
> Could xpath-default-namespace be an xpath-namespace-search-path? A
> list of namespaces which would resolve in order?  If I had a 'foo'
> that was in ns1, ns2 and ns3, I mainly want to be able to tell the
> processor the order of precedence in those namespaces. 


The concept of a name being "in" a namespace is valid in most
programming languages but is't really licensed by the namespace (Names
in XML) spec.

A name in XML either has an associated URI (namespacename) or doesn't.
We can't really have a search path because there's no reverse mapping,
from a namespace  name ot a list of names.

A schema will do it in some cases  - and i've met XML systems that
require it to be possible to dereference a namespace name as a URL and
to retrieve an XML Schema  document representtion (XSD) from it for
this purpose, but nothing in XML, Namespaces, XSD requires or even
endorses that behaviour.

We had only a couple of weeks to finish the namespace design; many of
the people doing it were not familiar with the architecture of the Web,
nor of Java's elegant approach. And the solution "had to" support RDF.
There was also a desire expressed to be able to copy and paste
fragments of plain text XML from  one document to another and have
automatic record of the originating documents' associated
namespaces(e.g. pasting an HTML fragment into a DocBook chapter) - and
a conflicting use case, being able to paste an "a" element from XHTML
(say) into a document in a vocabulary that happened to define a
compatible "a" element.

We ended up with a design in which namespaces, as Mike Kay points out,
are very different from qualified names in most programming languages,
and which are also not related to identifying authorities of controlled
vocabularies in library science, which is what RDF mostly needed.

This doesn't mean XML namespaces aren't of any use, but it does mean
they are rarely what newcomers to them expect them to be.

-- 
Liam Quin, https://www.delightfulcomputing.com/
Available for XML/Document/Information Architecture/XSLT/
XSL/XQuery/Web/Text Processing/A11Y training, work & consulting.
Barefoot Web-slave, antique illustrations:  http://www.fromoldbooks.org

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.