Sun has released version 0.7 of their JAXB (Java Architecture for XML
Binding) specification
introducing a partial -and controversial- support for W3C XML Schema.
JAXB defines the architecture and APIs enabling the binding of Java objects and
XML fragments. Following existing implementations such as Castor or Zeus,
JAXB relies on schemas to define the structure of XML documents.
Elliotte Rusty Harold criticizes this approach on his web site Cafe Con Leche:
JAXB compiles an XML schema into one or more Java classes. (First mistake:
JAXB assume there's a schema. Second mistake: It assumes the schema is
written in the W3C XML Schema Language. Third mistake: It assumes documents
actually adhere to the schema.)
More moderate readers will note that JAXB explicitly introduces a
"partial support" of W3C XML Schema, defining both the list of features that
an implementation will have to support to deserve a JAXB stamp and a list of
optional features which they can just ignore.
It's also worth noting that the list of optional features include XPath integrity constraints and
many of the so called "object oriented" features of W3C XML Schema such as:
- redefinitions,
- type substitutions,
- substitution groups,
- derivation
control attributes.
While the differences in the level and quality of support of W3C XML Schema between implementations have often be criticized, we are now starting to see specifications --including W3C's own XForms-- explicitly defining profiles of W3C XML Schema which could lead to "a la carte" partial implementations of this large and complex recommendation.
Other stories:
|