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

Relative Namespaces

  • From: Jeff Rafter <jeffrafter@e...>
  • To: xml-dev@l...
  • Date: Wed, 14 Mar 2001 16:59:24 -0800

relative namespace uri
Sorry if this question seems to have an obvious answer-- I just can't seem
to pin it down:

In the namespace spec [1] I read:

"A default namespace is considered to apply to the element where it is
declared (if that element has no namespace prefix), and to all elements with
no prefix within the content of that element. If the URI reference in a
default namespace declaration is empty, then unprefixed elements in the
scope of the declaration are not considered to be in any namespace."

...and lower...

"The default namespace can be set to the empty string. This has the same
effect, within the scope of the declaration, of there being no default
namespace."

...But in the Schema spec [2] I read:...

"Since the empty string is a legal (relative) URI reference, supplying an
empty string for targetNamespace is not the same as not specifying it at
all. The appropriate form of schema document corresponding to a schema whose
components have no {target namespace} is one which has no targetNamespace
attribute specified at all."

...And in the DOM Level 2 [3] Spec I read:...

"DOM Level 2 doesn't perform any URI normalization or canonicalization. The
URIs given to the DOM are assumed to be valid (e.g., characters such as
whitespaces are properly escaped), and no lexical checking is performed.
Absolute URI references are treated as strings and compared literally. How
relative namespace URI references are treated is undefined. To ensure
interoperability only absolute namespace URI references (i.e., URI
references beginning with a scheme name and a colon) should be used. Note
that because the DOM does no lexical checking, the empty string will be
treated as a real namespace URI in DOM Level 2 methods. Applications must
use the value null as the namespaceURI parameter for methods if they wish to
have no namespace."

...And finally in the Infoset Spec [4] I read:...

"Furthermore, this specification does not define an information set for
documents which use relative URI references in namespace declarations. This
is in accordance with the decision of the W3C XML Plenary Interest Group
described in [Relative Namespace URI References]. Thus the value of a
[namespace name] property is always an absolute URI with an optional
fragment identifier. "

======
Therefore I ask:  Where are we wrt to relative namespaces today--
sepcifically "".  I know that relative namespace use was deprecated [5] but
why do the DOM Level 2 and XML Schema specs still include the use of
relative namespaces when they were released after the deprecation decision?

[1] http://www.w3.org/TR/REC-xml-names/#defaulting
[2] http://www.w3.org/TR/xmlschema-1/#declare-typesElementsAttributes
[3]
http://www.w3.org/TR/DOM-Level-2-Core/core.html#Namespaces-Considerations
[4] http://www.w3.org/TR/xml-infoset/#intro
[5] http://www.w3.org/2000/09/xppa

Thanks,
Jeff Rafter


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.