Re: Validity of DOM documents

>(1) Will the DOM XML spec layer on top of the core (hiding the core),
>    or will it live beside the core, leaving both core interfaces and
>    DOM XML interfaces exposed?  Or is some other role intended?

The XML spec could be regarded as supplemental. It will add objects
for representing DTD's, and general entities. There should be few other
significant differences.

>(2) Will the DOM XML interfaces be expected to function with an
>    underlying DOM document that is invalid with respect to its DTD?

Yes.

>    It seems that such a model would need to expose ways for the
>    client to correct the document, which might require the client
>    to force the document through a series of invalid states before
>    ultimately arriving at a valid one.

This is correct. In essense, all editors do this at some point in time 
or another.

>(3) Will the DOM XML interfaces be able to enforce XML-specific
>    document rules so that a client generating (or modifying) an
>    XML document through the interfaces cannot create an invalid
>    document?  (This might require layering DOM XML on top of the
>    core XML so that the client cannot tweak the document directly.)

This is a point that is under debate. It would seem expensive to
require validation after (potentially) every operation that modfied
the tree in any way. Also, as I noted, this need is application
specific. 

>(4) Will other "levels" of DOM interact directly with the core DOM
>    and hence bypass constraints that might be specific to XML or
>    HTML or some other type of document?

In general, I think the DOM is taking a "layered" approach, where both
XML and HTML are "layered" on top of the core. As I noted above, the
XML spec does little layering per se, but does provide additional
constructs. 

Received on Wednesday, 3 December 1997 14:48:13 UTC