Re: Namespace treatment

keshlam@us.ibm.com wrote:
> 
> >You have confused me here. If the URI is bound to the name, then there
> >is no resolution necessary. Or did you mean the prefix?
> 
> The "name" is an attribute of the Node, and is made up of the namespace URI
> and the localname. The binding of Node (and thus name) to namespace URI
> occurs at the time the Node is created. It isn't expressed as a seperate
> "name" object, but I think it's equivalent to what you're asking for.

Well, only sort of.

<   Since
> object creation can be expensive in some environments, and names are
> immutable, I don't think a separate name object would be an improvement.

?
As they are immutable, were they to be interned, there would't need to
be recreated. It's an old argument.
> 
> > Until the namespace attributes are "normalized" the DOM is invalid.
> 
> The DOM doesn't currently check for validity; that's a Level 3 issue.  Did
> you mean "not well formed"?

I meant "not conforming to the namespaces in xml specification, as the
'prefix declared' constraint is not met". Keeping a DOM in conformance
with said spec is not a reasonable endeavour. As such, the namespace
attributes have no purpose in the DOM. One might one to keep them around
as hints to the serializer, but they're not of much other use.

>    Under the current design, the DOM doesn't
> enforce all the XML well-formedness rules; that too is a Level 3 issue.
> 
> If your point is that validation currently interacts badly with namespaces,
> I agree. But until schemas are released or someone redesigns DTD validation
> to be namespace-aware, there isn't a lot we can do about that.

No, that's a separate issue. 

...

Received on Monday, 6 March 2000 14:49:29 UTC