|
[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Crazy idea
From: Paul Prescod <paul@p...> >This "stylesheet as schema" idea comes around every so often but I think >that it has one major flaw: stylesheets cannot drive syntax directed >editors. Yes, but the idea is not "stylesheet as schema" but "validator implemented by stylesheet transformation language". As Francis Norton's tool (see previous email) shows, DCD (which is pretty suitable for a syntax-directed editor) validation can be implemented using XSLT. Also, why should a syntax-directed editor work outside-in (i.e., using content 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 a grammar can be specified. I do not see why a syntax-directed editor could not key off path expressions instead of the curent element type. That is surely how global exclusions and inclusion exceptions in SGML work: you can or cannot insert this element type because some ancestor's (extended) content model has allowed or banned it. >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 are Here here. >pretty much the same. The XSLT set of languages would be radically >different. What's the XSLT equivalent for this content model: > >((a*,(b|c)+,d)+|(d,(b|c)*,d?)+) It would be a lot of typing in XSLT, but it cannot see why it could not be done. It can be a transformed from a schema anyway. Another possibility is also that a validator need not perform all possible validations to be still useful. I have a note "Weaker Validation" at http://www.ascc.net/xml/en/utf-8/weakvalid.html 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@i... Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/ and on CD-ROM/ISBN 981-02-3594-1 To (un)subscribe, mailto:majordomo@i... the following message; (un)subscribe xml-dev To subscribe to the digests, mailto:majordomo@i... the following message; subscribe xml-dev-digest List coordinator, Henry Rzepa (mailto:rzepa@i...)
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|
|||||||||

Cart








