[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Does DTD validation work with namespaces?

  • From: Marcus Carr <mrc@a...>
  • Date: Thu, 10 Aug 2000 10:12:46 +1000

well sourced well formed

Wayne Steele wrote:

> DTD Validation is intended to allow documents to specify the model and
> constraints they adhere to, not to force documents to conform to some
> outside spec.

Idle musings only...

Given that DTDs are for parsing for validity, it might not be unreasonable to
expect that the entire document will be checked against their various DTDs. Since
a DOCTYPE declaration is used to signal the start of a new document, it would be
ideal if that concept could just be extended, allowing a number of DOCTYPEs to
coexist in a single compound document. Each time a new DOCTYPE was encountered,
processing of the parent document would be suspended and the documents processed
recursively. The existence of a nested document would have no impact on the
structure of the parent document - it wouldn't even need to be anticipated in the
DTD.

Using OmniMark, you can parse all of the DTDs and have them ready for use. You
could easily define a NOTATION for the namespace prefix and attach it to the
elements on output, generating properly namespaced documents. The only thing
preventing it is the fact that a DOCTYPE declaration in the middle of a document
needs to result in an error. (A fairly well-sourced rumour has it that they have
processed XML inside an SGML document in the OmniMark lab, so technically,
nesting wouldn't be an issue.)

Of course, the approach above locks you into the whole document being able to be
processed for validity (validatable?) or not - no mixing could be supportted.
There are probably numerous other reason that it isn't practical, but in the
dataflow whereby data is validated at the source and then considered well-formed
from that point on, it seems tantalisingly close to being possible. I'm not
proposing change, just speculating about how in a specific scenario, namespaces
and DTDs might work together.


--
Regards,

Marcus Carr                      email:  mrc@a...
___________________________________________________________________
Allette Systems (Australia)      www:    http://www.allette.com.au
___________________________________________________________________
"Everything should be made as simple as possible, but not simpler."
       - Einstein



PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.