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] xml schema

[ Lists Home | Date Index | Thread Index ]

It has no discernable bias if you're not versed in the subject matter. The article smacks of FUD in a number of areas from 
"To be precise, you can always write it without understanding complex types, but unfortunately you have to type <complexType> elements."
followed by 

"Just consider a <complexType> as something you have to write as a sole child of the <element> element. That is, you write element declarations as follows:

<sni p/> 

Why spend your precious time learning something you don't need? Convinced? Then there is no need to read more."
or even 
"Inheritance is a complex type's only advantage, but you really don't want to use it." 
Or my personal favorite piece of FUD 
"What do you get by using the restriction? Error checking. That's it. Validators are supposed to report an error if you fail to make a content model a restricted one. Unfortunately, this is hardly an advantage. 

First, strictly enforcing this check is a difficult job for validators. You can look at the part of the spec that defines this constraint <http://www.w3.org/TR/xmlschema-1/#coss-particle> . The entire section 3.9.6 is devoted to specifying what is allowed and what is not. There's a strong temptation for developers to skip the enforcement of this constraint because most people won't notice that the check is skipped. "

Loosely translated, don't use this feature because 1 month after the  technology became a W3C recommendation implementations are still buggy and I believe developers are too lazy and too dumb to implement it anyway. 
The article is a FUD fest. Every genuine concern is exaggerated while phantom almost nonsensical  concerns are constructed in an attempt to discredit the technology. 

	-----Original Message----- 
	From: Paul Prescod [mailto:paul@prescod.net] 
	Sent: Sun 9/1/2002 11:22 AM 
	To: Dare Obasanjo; xml-dev@lists.xml.org 
	Subject: Re: [xml-dev] xml schema

	Dare Obasanjo wrote:
	> In my personal opinion, an article that advises against using complex
	> types in W3C XML Schema cannot claim to be without bias.
	*In context* the admonisment seems quite reasonable to me. Essentially
	he is saying: "XML Schema allows you to make a distinction between types
	and elements but most people can get away without such a distinction and
	arguably the distinction is not useful anyhow. So use a subset of XML
	Schema that re-unifies elements and types and get on with life."
	Note that he never said: "don't type <xs:complexType>" because then XML
	Schema would really be useless. He said don't treat the element as a
	first-class concept. Treat it as boilerplate syntax.
	"Furthermore, you won't lose anything by not using complex types: if a
	schema can be written by using complex types, then you can always write
	it without complex types. To be precise, you can always write it without
	understanding complex types, but unfortunately you have to type
	<complexType> elements."
	 * http://www.xml.com/pub/a/2001/06/06/schemasimple.html#avoid_complex
	"In short, a complex type is a model group, plus inheritance, minus ease
	of use. A complex type and a model group are similar in the sense that
	they are used to define content models. A complex type lacks ease of use
	because you can't use it from other complex types or model groups. On
	the other hand, model groups can be used without such restriction."
	"... None of these problems occur if you use model groups instead of
	complex types. When it comes to derivation by restriction, a general
	understanding isn't enough; you need a very detailed understanding of
	how it works."
	So whether he is right or wrong, he argues clearly and IMO, without any
	discernable bias. The article does seem a bit "rushed" and the points
	could have been stated more clearly. For instance he could have said:
	"Do not use complex types outside of element declarations."
	 Paul Prescod


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

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