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

RE: Substitution Groups - Use 'em or lose 'em?


hierarchical substitution groups
It's true that every schema processor has bugs, and/or documented restrictions. However, there's a big difference between restrictions in obscure corner cases where it isn't at all clear what the correct behavior is (for example, using a QName as a default value) and failing to support major facilities like substitution groups.
 
As Henry pointed out, the biggest difficulty arises not with validators but with data binding tools. Personally I'm no great fan of data binding tools: it's much better to write your application in a language that has XML Schema as its native type system (i.e., XSLT or XQuery) than to mess around converting your data between two very different representations.
 
My (recent) experience is that if a schema is passed by Xerces, MSXML3, XSV, and Saxon then it's a good schema, and if you get differences between these processors then you're probably in an area where the spec is wobbly.
 
Michael Kay
http://www.saxonica.com/


From: Paul Spencer [mailto:xml-dev@b...]
Sent: 30 August 2005 11:32
To: Michael Kay; Xml-Dev
Subject: RE: Substitution Groups - Use 'em or lose 'em?

I've yet to find one with no bugs. All I can say is that some are better than others. Which do you regard as "good" schema processors? I currently test any schemas I produce with five processors, but all have their errors and omissions- mostly false passes, but also some with false fails. The latter are pretty useless in my opinion, but unfortunately one is popular so I try to design around the errors. I'm not going to say which have the most errors, but I find Xerces 2.7 and MSXML4 SP2 pretty good.
 
The most common fault I have found with substitution groups is that processors will "pass" schemas where the substituting item is incorrectly derived (or not derived at all) from the substituted item. My guess is that testing only using processors with this fault is the reason that the errors in, for example, GML3.1 were not found before release, making these schemas useless in practice, and not easy to correct.
 
But back to original subject, substitution groups are a great extensibility mechanism because of the ability to use them with third party schemas without altering the original schemas. The only problems I find are the limitations of the derivation rules - for example, not being able to restrict a list of enumerations.
 
Paul Spencer
-----Original Message-----
From: Michael Kay [mailto:mike@s...]
Sent: 30 August 2005 09:41
To: 'Marty Burns'; xml-dev@l...
Subject: RE: Substitution Groups - Use 'em or lose 'em?

There are several good schema processors around. If you have a buggy one that doesn't support the language properly, throw it out.
 
Michael Kay
http://www.saxonica.com/


From: Marty Burns [mailto:burnsmarty@c...]
Sent: 29 August 2005 23:50
To: xml-dev@l...
Subject: Substitution Groups - Use 'em or lose 'em?

We are working on extensibility models for standardized business exchange
schemas. These schemas, under development by several standards organizations
make extensive use of hierarchical schemas and namespaces, some of which
include schemas developed by third parties.

When a user or user community seeks to use these schemas, and, needs to
modify them in some way (without altering the underlying standardized
schemas), substitution groups can be a powerful and explicit mechanism for
such extensions and restrictions.

Several participants in these standard schema efforts have expressed reserve
from utilizing the W3C mechanism of substitution groups due to their
experience with non-uniform support of parsers for this schema feature.

In your experience, what are the concerns or recommendations on the
incorporation of substitution groups into the naming and design rules of
standardized schemas?

Should substitution groups be relied upon as an extension mechanism?

Marty Burns
Hypertek, Inc.
P +1(301)315-9101
E burnsmarty@a...

 

 

 


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.