[XML-SIG] RELAX in lieu of XML Schema?
Michael McLay
mclay@nist.gov
Sun, 23 Apr 2000 18:46:20 -0400 (EDT)
Andrew M. Kuchling writes:
> Andy Heath writes:
> >Are you guys doing anything about XML Schema?
> >
> >I know the spec is not out there in any final'ish form
> >yet but IMHO the whole world will go that way when it is.
>
> I don't know if anyone is working on XML Schema support, but your
> message gave me the impetus to go to www.w3.org to take a look at the
> working drafts.
>
> To my horror, the two parts of the XML schema WDs are 520K and 360K of
> HTML; that's huge! (XML 1.0 is 188K.) Didn't people want schemas
> because they thought DTD syntax was too complicated?
The Schema committee lost control of the scope of the project. A
typical standards committee mistake. Yet another standard that may
have become so complex that it will never be consistently
implemented. I'd like to see XML Schema available for Python, but I'd
be happy with any DTD replacement mechanism be used that allows typing
information and namespaces to be managed.
Has anyone looked at RELAX, http://www.xml.gr.jp/relax/ ? It is a
smaller and easier to implement alternative to XML Schema. Here's a
quote from an article about RELAX that sums up why I think it might be
a good first step towards adding schema capabilities to Python.
Murata had hit the 80/20 mark that they [the XML Schema committee]
had missed. RELAX core could provide a much easier on-ramp to
schemas for application and schema authors than the W3C draft
which is not modular.
[...]
Our First Take. We share the stunned admiration for Murata's lone
samurai charge. On first analysis, RELAX appears to combine greater
simplicity in approach, exposition and execution with greater power-a
compelling combination under any circumstances. Given the low but
omnipresent level of grumbling over the length, complexity and
compromises of the W3C spec, RELAX will be given every chance to live
up to its claims.
Backing up his claim to ease of implementation, Murata's group
already has made available a Java converter from DTDs to RELAX and a
validator written in C++,with source code to come under an open source
license. As Sperberg-McQueen indicated, ultimately adoption rests with
the marketplace. One very strong point in favor of RELAX is that it
can be implemented without ripping out existing XML processors and
APIs. Because the Core module is a direct DTD replacement, no
extensions are required to DOM and SAX implementations. RELAX grammar
validation, with datatypes, can be added as a subsequent step.
- http://www.seyboldreports.com/News/2000/20000307.html
The C++ code isn't available in a format I recognize. The file name
is regular1.lzh. The strings function located 51 .cpp file names and
120 .h file names. I would assume that the code could be added to the
XML package as an optional post DOM processing step. Someone with
SWIG or SIP experience could probably have the new module with RELAX
capability up and running quickly. I don't see a down side to adding
RELAX as a feature of the XML package. An XML Schema processing
engine could be added along side of RELAX when and if XML Schema
starts to be adopted widely.
An article on RELAX at http://www.xml.com/pub/2000/02/xtech/relax.html
also includes a review of Paul Prescod's EasySAX. Did I miss this
article being referenced on this mailing list? There doesn't seem to
be list of articles on Python and XML in the xml-sig pages. EasySAX
was also described in http://www.javaworld.com/jw-03-2000/jw-03-xmlshow.html