You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-users@xerces.apache.org by Karl Scheibelhofer <Ka...@iaik.at> on 2001/05/09 08:21:24 UTC

RE: importNode does not care about IDs

i contacted the DOM mailing list for clarification. 
here is an answer:

-----Original Message-----
From: www-dom-request@w3.org [mailto:www-dom-request@w3.org]On Behalf Of
Joseph Kesselman
Sent: Tuesday, May 08, 2001 7:13 PM
To: www-dom@w3.org
Subject: Re: importNode and handling of ID attributes



>is it the responsibility of the 'importNode' function to take care of ID
>attributes?

Yes, _IF_ the importing DOM understands IDs and has the information
available to determine whether an attribute is or isn't an ID. As 
you point
out, this currently relies on some undocumented and unexposed magic within
the DOM implementation, so the right answer is to check your DOM
implementation's documentation to find out what it does. (Not all 
DOMs have
or use ID information, as we mentioned in the description of
getElementByID.)

Note that the question of which attributes are and aren't IDs would be
determined by the importing document, _not_ by the source document.

Again, DOM Level 3's DTD/Schema support will provide a more rigorous
definition of this behavior, for those DOMs which choose to implement that
module.

______________________________________
 Joe Kesselman  / IBM Research




> -----Original Message-----
> From: Andy Clark [mailto:andyc@apache.org]
> Sent: Friday, April 20, 2001 11:45 AM
> To: xerces-j-user@xml.apache.org
> Subject: Re: importNode does not care about IDs
> 
> 
> Karl Scheibelhofer wrote:
> > you misunderstood me, i think. 
> 
> I believe that I understand your question. But maintaining
> ID state on importNode doesn't make much sense. It's a shame
> that the DOM doesn't have a standard way of registering ID
> attributes in the document but I don't think that the DOM
> implementation should carry those IDs over to the document
> where the node is imported. Arnaud: what is your opinion?
> 
> -- 
> Andy Clark * IBM, TRL - Japan * andyc@apache.org
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: xerces-j-user-unsubscribe@xml.apache.org
> For additional commands, e-mail: xerces-j-user-help@xml.apache.org
> 
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-j-user-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-j-user-help@xml.apache.org