W3C home > Mailing lists > Public > www-dom-ts@w3.org > February 2003

Re: key attribute missing in generated dtd

From: Curt Arnold <carnold@houston.rr.com>
Date: Tue, 04 Feb 2003 23:44:11 -0600
Message-ID: <3E40A4AB.6080108@houston.rr.com>
To: jeroen@x-hive.com, www-dom-ts@w3.org

Jeroen van Rotterdam wrote:
> DOMBuilder has the following method:
> 
> DOMBuilder.abort(String key)
> 
> The generated dtd contains:
> 
> <!ELEMENT abort EMPTY >
> <!ATTLIST abort
>     id ID #IMPLIED
>     obj CDATA #REQUIRED
>     interface (DocumentLS|DOMBuilder) #REQUIRED
> 
> Which is lacking the key attribute.......
> Probably has something to do with the name "key"
> 
> 
> Any idea ?

The listing of DocumentLS and DOMBuilder as potential values for 
interface would suggest that you generated the DTD from a draft where 
both interfaces had an "abort" method (which isn't the case in the last 
public draft).

Neither dom-to-dtd.xsl or dom-to-xsd.xsl is sufficiently smart enough to 
fabricate a common element definition from conflicting definitions of 
the same method name.  It generates the element from one (probably first 
in document order in the combined spec) and assumes that any other use 
will be compatible.  When that isn't the case, you have to suppress the 
automatic generation and provide a hand-crafted element.  The exclusion 
of 'load' on line 240 of dom-to-dtd.xsl is an instance of this effect. 
(Related is a fixup in the dom?-combine.xsl that make the argument names 
of Element.getElementsByTagName and Document.getElementsByTagName 
identical).

You might review whether both "abort" methods are needed or whether 
their arguments could be synchronized.

If you explicitly specify the interface attribute, the test-to-xxx.xsl 
transforms should not have a problem.
Received on Wednesday, 5 February 2003 00:44:20 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 20:34:06 UTC