Re: [xml] Copy properties and namespaces



On Thu, Feb 15, 2007 at 02:07:36PM -0800, Yong Chen (yongche) wrote:

Thanks Daniel. My test shows that for copying namespaces, I only need to
do: 

               B->nsDef=xmlCopyNamespaceList(A->nsDef);

And I don't need to do following:

               B->ns=xmlCopyNamespaceList(A->ns);


So what's the difference between "ns" and "nsDef" of a node?

  nsDef are the namespace definitions on an Element
  ns just point to the namespace used by an Element or an Attribute

Daniel

-- 
Red Hat Virtualization group http://redhat.com/virtualization/
Daniel Veillard      | virtualization library  http://libvirt.org/
veillard redhat com  | libxml GNOME XML XSLT toolkit  http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine  http://rpmfind.net/



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]