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

Re: Enlightenment via avoiding the T-word

  • From: Rick Jelliffe <ricko@a...>
  • To: xml-dev@l...
  • Date: Tue, 28 Aug 2001 19:27:27 +1000

usage of word through
From: "Nicolas LEHUEN" <nicolas.lehuen@u...>

> Well I wouldn't be surprised that by adhering to the "all-global" policy, we
> would soon find our namespaces too small... Let's consider this (somewhat
> corny) "purchase" sample with local elements :
> 
> <purchase xmlns="http://foobar/purchase">
> <customer>
> <name>Nicolas</name>
> <address>Paris, France</address>
> </customer>
> <delivery>
> <mode>UPS</mode>
> <address>Somewhere else</address>
> </delivery>
> <lines>
> <line>
> <!-- duh, will this wake up Echelon :) ? -->
> <product>
> <name>ACME Explosives</name>
> <price currency="dollar">2000</price>
> </product>
> <quantity>200</quantity>
> </line>
> </lines>
> </purchase>

Sorry, where are the local types in this?   You need to provide a schema
or some clearer indication, otherwise I cannot follow the example. But it
doesn't seem very convincing, from what I can follow: to say that
having "mode" and "mode" with different meanings is preferable to
having "mode" and "deliveryMode" is baffling. [Of course context will
be useful for figuring out the meaning of an element when you first
come to it; but if the meaning is different depending on each context
(without warning) there is no way to synthesize the meaning from
the multiple contexts.]

On the concrete point of not wanting to use different namespaces because it
complicates things, namespaces are the W3C technology for preventing
name clashes and allowing modularization.  They are the appropriate thing
to use, if it is impossible to figure out alternative names. If you don't want
to use multiple namespaces, why even use one?

If your tools don't handle schemas with multiple namespaces well, get better tools,
don't foist PSVI on the rest of us :-)

> Problem is, the only way to have both global
> element names only AND achieve modularity and extensibility is to
> extensively use namespaces, 

Yes, if you want to reuse local names, you need as many namespaces
as you have re-uses.  That's the way it should be: no local names, no
local types. If different columns in tables in DBMS have the same name, 
it is a mapping issue not something that should be needed by an XML
schema language.  And if it makes auto-generated Java more complicated, 
boo hoo. 

Cheers
Rick Jelliffe


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.