- From: Noah Mendelsohn <nrm@arcanedomain.com>
- Date: Sat, 19 Mar 2011 17:09:32 -0400
- To: "Costello, Roger L." <costello@mitre.org>
- CC: "xmlschema-dev@w3.org" <xmlschema-dev@w3.org>
If that's really true in his case, then he or she should use Schematron + XSD. It's a fine combination if it meets your needs for validation, interchange, data binding, or whatever. That's a little like saying to me: gee, my user is really happy using Python, my C# system just added closures, but it still doesn't feel like Python. What should I tell my user? Well, enjoy using Python. Then again, if you are one of the many satisfied users of C#, or you just need it because you are integrating with a Windows system or whatever, you may be really happy that C# has picked up a new feature, inspired by another language that you like. That's not to say that it wouldn't be nice if XSD could so completely, conveniently and simply subsume all the great characteristics of Schematron that nobody would ever look back, but not surprisingly, languages that proceed from differing design points have differing strengths. If you want languages that emphasize reusablility of element or attribute declarations, then DTDs or Schemas (which are intentionally very similar in this respect) are probably better. If you want a system that supports databinding, I suspect XSD is better. I don't know whether Schematron could have served as a type system for XQuery, but I suspect not. I should say one can imagine some rather cool query languages based on Schematron, but they would have been quite different. So, different languages have different feels and different strengths. The goal here was to incrementally improve XSD. The changes were acknowledged to be influenced by Schematron, and it certainly intended that certain sorts of uses of XSD + Schematron (e.g. that min <= max) check can now be done without resorting to separate validation steps. If you're happy with Schematron, then that's what you should use. Noah On 3/19/2011 3:57 PM, Costello, Roger L. wrote: > Hi Noah, > >> Bottom line: if Schematron is what you want, by all means use it, either >> alone, or in conjunction with XSD. > > One student made the following remark after learning of the restrictions on<assert> and<alternative> and the inheritable attributes: > > I see no reason for using XML Schema 1.1 since > I can do everything (and more) using the combination of > XML Schema 1.0 and Schematron. Plus, with > Schematron I get friendly, user-defined > diagnostic messages, which I don't get from > either XML Schema 1.0 or 1.1 > > How would you respond to that? What does XML Schema 1.1 give that can't already be obtained using XML Schema 1.0 and Schematron? > > /Roger > > >
Received on Saturday, 19 March 2011 21:10:02 UTC