[Bug 4992] Object identity needs to be clarified

http://www.w3.org/Bugs/Public/show_bug.cgi?id=4992


sandygao@ca.ibm.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |hasProposal




------- Comment #5 from sandygao@ca.ibm.com  2007-11-08 17:13 -------
To restate the the proposal from the F2F in a slightly different fashion, and
to answer Ginny's questions. The proposal was:

1. There are cases where processors MUST treat nodes as "the same".

The only known case is when the targets are identified using URIs in contexts
where the URI has all the information about locating/identifying the target,
then 2 targets are the same if they are identified by the same
(codepoint-by-codepoint comparison) URI.

SML URI scheme is one such example. EPR is not because URIs used in EPR don't
have all the information. It should be clear from new schemes definitions
whether they fall into this category or not.

2. There are cases where processors MUST treat nodes as "different".

This happens when there is something available in the element information items
for the targets that tells them apart. If there is an infoset property for
which the 2 targets have different values, they are different. This applies
recursively for complex-valued properties.

3. For all other cases, it's impl-dependent whether they treat nodes as
different or same.


This (especially #2) may sound like a time-consuming task. But I imagine in
most implementations, this can be tested very easily. e.g. in DOM, if you only
construct one DOM document for each model instance document, then the "=="
comparison suffices.

Received on Thursday, 8 November 2007 17:14:00 UTC