Crazy idea

Rick Jelliffe ricko at
Mon Sep 6 19:54:58 BST 1999

From: Paul Prescod <paul at>

>This "stylesheet as schema" idea comes around every so often but I
>that it has one major flaw: stylesheets cannot drive syntax directed

Yes, but  the idea is not "stylesheet as schema" but "validator
implemented by
stylesheet transformation language".  As Francis Norton's tool (see
email) shows, DCD (which is pretty suitable for a syntax-directed
validation can be implemented using XSLT.

Also, why should a syntax-directed editor work outside-in (i.e., using
models). That the currently do so is because they use grammars where the
children are keyed by the parent, but that is not the only way in which
grammar can be specified.

I do not see why a syntax-directed editor could not key off path
instead of the curent element type. That is surely how global exclusions
inclusion exceptions in SGML work: you can or cannot insert this element
because some ancestor's (extended) content model has allowed or banned

>From a mathematical point of view, I don't think that XSchemas are much
>stronger than DTDs. The set of tag-based languages they can describe

Here here.

>pretty much the same. The XSLT set of languages would be radically
>different. What's the XSLT equivalent for this content model:

It would be a lot of typing in XSLT, but it cannot see why it could not
done. It can be a transformed from a schema anyway.

Another possibility is also that a validator need not perform all
validations to be still useful. I have a note "Weaker Validation" at on this. In particular,
for documents in development is it useful to have a weaker validation.

>On the other hand there are constraints that XSLT could support that
>schemas probably could not.

I think abbreviated RDF and XML namespaces should be test cases for
XML schemas: if they can handle those, then we have a clear advance.

Rick Jelliffe

xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev at
Archived as: and on CD-ROM/ISBN 981-02-3594-1
To (un)subscribe, mailto:majordomo at the following message;
(un)subscribe xml-dev
To subscribe to the digests, mailto:majordomo at the following message;
subscribe xml-dev-digest
List coordinator, Henry Rzepa (mailto:rzepa at

More information about the Xml-dev mailing list