[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: Enlightenment via avoiding the T-word
- From: Michael Brennan <Michael_Brennan@allegis.com>
- To: 'Tim Bray' <email@example.com>, firstname.lastname@example.org
- Date: Mon, 27 Aug 2001 18:50:02 -0700
I still can't help feeling that the real heart of the problem is the PSVI.
Because Schemas support the notion of a PSVI that includes "types" (sorry
for use of that word), developers want to leverage that info. But that info
is not in the instance document, and is not normally accessible to
applications because prevailing schema processors just use the info for
validation. The info is locked away in a black box.
The root of the problem seems to me this notion that there is information
inherent in a document that is not in the document instance itself. The PSVI
should be treated as a sort of lightweight transformation. What is currently
described as "schema validation" should really be two separate tasks (though
they could be conducted in concert):
* Validate a document instance to ensure it conforms to constraints
necessary for processing.
* Transform a document instance that satisfies these constraints into a form
more useful to an application. This may entail adding default attribute
values, IDs, or additional annotations to the infoset such as a "ulabel"
(perhaps in the form of elements and/or attributes belonging to a special
PSVI namespace) that are of use to the application.
Thus, an element definition could have two dimensions to it: lexical
constraints for validating content, and rules for annotating content with
The more we think there is information inherent in a document that is not
there in the instance itself, the more people feel encouraged to layer
notions such as datatypes, inheritance, etc. unto XML in a fashion that
pollutes the foundation.
> Would the XPath trick qualify? Because there are a *lot* of
> philosophical problems with actually changing the element labels
> to accomplish this objective. Keepa yo hands offa my labels, geekboy!
But aren't the philosophical problems rooted in the notion that there is
this PSVI that must be made available to applications while keeping the
document instance inviolate (except for a few blessed annotations, such as
adding default attribute values), and that this PSVI is something inherent
in this document instance rather than something derived from it based on
some clear rules?