W3C home > Mailing lists > Public > www-dom@w3.org > October to December 1998

RE: Relation between core DOM and HTML DOM

From: Miles Sabin <msabin@cromwellmedia.co.uk>
Date: Wed, 14 Oct 1998 18:23:40 +0100
Message-ID: <c=US%a=_%p=Cromwell_Media%l=ODIN-981014172340Z-22076@odin.cromwellmedia.co.uk>
To: "'Arnaud Le Hors'" <lehors@w3.org>, "'DOM list'" <www-dom@w3.org>
Just to confirm the impressions I get from this thread:
am I right to assume the the intended behaviour is as
follows:

  Document someXMLDoc = new BasicDocument();
  Element xmlElement = someXMLDoc.createElement("FOO");
  Element htmlLikeElement = someXMLDoc.createElement("TABLE");

  if(xmlElement instanceof HTMLElement)
    // always false

  if(htmlLikeElement instanceof HTMLElement)
    // always false

  HTMLDocument someHTMLDoc = new BasicHTMLDocument();
  Element xmlLikeElement = someHTMLDoc.createElement("FOO");
  Element htmlElement = someHTMLDoc.createElement("TABLE");

  if(xmlLikeElement instanceof HTMLElement)
    // always true

  if(htmlElement instanceof HTMLElement)
    // always true

  if(htmlElement instanceof HTMLTableElement)
    // always true

If this is the intention of the REC (and I hope it is), then
it needs to be spelt out.

Cheers,


Miles

-- 
Miles Sabin                          Cromwell Media
Internet Systems Architect           5/6 Glenthorne Mews
+44 (0)181 410 2230                  London, W6 0LJ
msabin@cromwellmedia.co.uk           England
Received on Wednesday, 14 October 1998 13:28:50 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Friday, 22 June 2012 06:13:45 GMT