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

RE: Namespaces A Mess? (was: Candle 0.8 - a new scripting language f

  • To: "'Doug Schepers'" <doug@s...>,<xml-dev@l...>
  • Subject: RE: Namespaces A Mess? (was: Candle 0.8 - a new scripting language for XML)
  • From: "Michael Kay" <mike@s...>
  • Date: Sun, 16 Oct 2005 00:27:11 +0100
  • In-reply-to: <20051015204527.5FC5314968E@p...>
  • Thread-index: AcXPNig5BLmgB/uRQ+iKVXCoVMu7cQACUYrQAKIl3SAABU6WAA==

language f
Just look at the xsl-list archives and see the proportion of user problems
that are caused by namespaces.

Or, if you were able, look at the minutes of any W3C working group and see
the proportion of its effort that goes into dealing with the complexities
caused by namespaces.

The main issues are:

(a) exactly what strings are permitted as namespace URIs? Different specs
differ on the point.

(b) are namespace declarations information-bearing? For example, are the two
documents below equivalent:

    (1) <a xmlns:x="x"><b/></a>
    (2) <a xmlns:x="x"><b xmlns:x="x"/></a>

(c) are in-scope namespaces that are not referenced information-bearing? For
example, are either of the above documents equivalent to:

    (3) <a><b/></a>

    (the main problem here, of course, is "QNames in content": the use of
namespace-sensitive element and attribute values. But there are also
applications that use the mere presence of a namespace declaration as a flag
or marker.)

(d) are prefixes information-bearing? That is, is document (1) equivalent
to:

    (4) <a xmlns:y="x"><b/></a>

    (again, the problem is "QNames in content")

(e) in the light of the above, how should namespaces be handled by
applications that allow a document to be modified? For example, if an
element is deep-copied from one place to another, should it take all its
in-scope namespace declarations with it?

(f) DTDs are an intrinsic part of XML, but DTDs are not namespace-aware.

(g) How should namespaces be versioned?

 
At a higher level, namespaces cause immense design difficulty. How should a
large organization creating hundreds of XML document definitions manage its
allocation of namespaces? You could say that any naming scheme would have
this problem. However, the design of XML namespaces is optimized for
situations in which the number of namespaces is small (more than five in a
document gets unwieldy). This makes namespace management very difficult.

There's a basic root cause of many of the difficulties, which is that naming
in any information architecture is absolutely fundamental, yet the naming
architecture of XML has been "patched in" as an afterthought at a layer
above the core. That, plus the fact that the information model itself (the
infoset) is non-prescriptive and layered above the core.

Michael Kay




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
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

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.