Re: Proposal Announcement - XML DTDs to XML docs

Ron Bourret (rbourret@dvs1.informatik.tu-darmstadt.de)
Fri, 22 May 1998 11:45:58 +0200


A couple of comments about the example on your Web page:

<ELEMENT TAG=3D"FIGURE">
<CONTENTMODEL>IMAGE,CAPTION?</CONTENTMODEL>
<ATTRIBUTE NAME=3D"DESCRIPTION">
<ATTCONTENT>CDATA</ATTCONTENT>
<ATTREQUIRED>#IMPLIED</ATTREQUIRED>
</ATTRIBUTE>
</ELEMENT>

Content model should contain sub-elements, such as <ELEMENTUSE>, not =
text. You=20
don't want to force applications to parse text. On the other hand, =
attribute=20
descriptions are probably better stored in attributes:

<ATTRIBUTE NAME =3D "DESCRIPTION" CONTENT =3D "CDATA" REQUIRED =3D =
"OPTIONAL">
=20
The reason is that the possible choices are limited and work very well =
as=20
enumerated attributes. Note that this is what XML-Data does. If you =
are=20
defining some sort of XML-Data-Lite, XML-Data is probably a pretty good =
starting=20
place.

-- Ron Bourret