validation design really supported by typing requirements?

I got the impression that certain design decisions
in XML Schema are justified by a requirement to
be able to associate types with parts of documents.
But in a discussion in xmlschema-dev in Jun 2001,
I wasn't able to defend this position...


in W3C XML Schema validation,
the result includes not just a "yes, this is valid"/"no, not valid"
but also "and this part of the input matched this part of the
schema" i.e. "it has this type, is associated with this annotation"


the other languages won't give you type/annotation
info as a result of checking.


But K.Kawaguchi disagreed:

I then went to study the relax NG spec to
see if I could understand it for myself.
I never quite learned the answer...

The thread continued; K.Kawaguchi concluded with:

The only difference, with regard to the type assignment, between RELAX
NG and W3C XML Schema is that W3C XML Schema ensures that you can always
tell the type of elements/attributes when you see its startElement SAX
event, whereas RELAX NG doesn't.

But the way W3C XML Schema ensures this is ad hoc. As a result, many
grammars (including the one written by Geoff) are prohibited even though
they satisfy this property.

I have to say that, after trying to capture
XML Schema part 1 in larch, and looking[1]
at the relaxNG formalization[2],
I find myself agreeing with the "ad hoc"
characterization of XML Schema part 1.


So please, in any future XML Schema requirements document,
explain exactly what requirements motivate various
validation constrants; e.g. why <all> cannot have repetitions
or be nested within a <sequence>.

FYI, my interest in the matter is renewed by recent TAG discussions...

  2.1.1 Augmented infosets, PSVI
  Minutes of 17 June 2002 TAG teleconference

which followed from a large thread...

# Potential new issue: PSVI considered harmful Tim Bray (Wed, Jun 12

That thread suggests a new requirement: that type augmentation
should be orthogonal to validation. I haven't studied that
suggestion well enough to endorse it yet, but FYI, you
may get a request for it sometime soon.

Dan Connolly, W3C

Received on Tuesday, 18 June 2002 17:05:11 UTC