summaryrefslogtreecommitdiff
path: root/doc/devhelp/libxml2-tree.html
diff options
context:
space:
mode:
Diffstat (limited to 'doc/devhelp/libxml2-tree.html')
-rw-r--r--doc/devhelp/libxml2-tree.html17
1 files changed, 11 insertions, 6 deletions
diff --git a/doc/devhelp/libxml2-tree.html b/doc/devhelp/libxml2-tree.html
index 9395f76..d7757e3 100644
--- a/doc/devhelp/libxml2-tree.html
+++ b/doc/devhelp/libxml2-tree.html
@@ -131,6 +131,7 @@ int <a href="#xmlSaveFormatFileTo">xmlSaveFormatFileTo</a> (<a href="libxml2-tr
int <a href="#xmlNodeBufGetContent">xmlNodeBufGetContent</a> (<a href="libxml2-tree.html#xmlBufferPtr">xmlBufferPtr</a> buffer, <br/> <a href="libxml2-tree.html#xmlNodePtr">xmlNodePtr</a> cur);
void <a href="#xmlBufferWriteChar">xmlBufferWriteChar</a> (<a href="libxml2-tree.html#xmlBufferPtr">xmlBufferPtr</a> buf, <br/> const char * string);
void <a href="#xmlBufferFree">xmlBufferFree</a> (<a href="libxml2-tree.html#xmlBufferPtr">xmlBufferPtr</a> buf);
+int <a href="#xmlDOMWrapCloneNode">xmlDOMWrapCloneNode</a> (<a href="libxml2-tree.html#xmlDOMWrapCtxtPtr">xmlDOMWrapCtxtPtr</a> ctxt, <br/> <a href="libxml2-tree.html#xmlDocPtr">xmlDocPtr</a> sourceDoc, <br/> <a href="libxml2-tree.html#xmlNodePtr">xmlNodePtr</a> node, <br/> <a href="libxml2-tree.html#xmlNodePtr">xmlNodePtr</a> * resNode, <br/> <a href="libxml2-tree.html#xmlDocPtr">xmlDocPtr</a> destDoc, <br/> <a href="libxml2-tree.html#xmlNodePtr">xmlNodePtr</a> destParent, <br/> int deep, <br/> int options);
<a href="libxml2-tree.html#xmlNodePtr">xmlNodePtr</a> <a href="#xmlNewNode">xmlNewNode</a> (<a href="libxml2-tree.html#xmlNsPtr">xmlNsPtr</a> ns, <br/> const <a href="libxml2-xmlstring.html#xmlChar">xmlChar</a> * name);
int <a href="#xmlSaveFileTo">xmlSaveFileTo</a> (<a href="libxml2-tree.html#xmlOutputBufferPtr">xmlOutputBufferPtr</a> buf, <br/> <a href="libxml2-tree.html#xmlDocPtr">xmlDocPtr</a> cur, <br/> const char * encoding);
<a href="libxml2-tree.html#xmlNodePtr">xmlNodePtr</a> <a href="#xmlNewTextLen">xmlNewTextLen</a> (const <a href="libxml2-xmlstring.html#xmlChar">xmlChar</a> * content, <br/> int len);
@@ -1009,8 +1010,12 @@ void <a href="#xmlFreeNsList">xmlFreeNsList</a> (<a href="libxml2-tree.html#xm
<div class="variablelist"><table border="0"><col align="left"/><tbody><tr><td><span class="term"><i><tt>doc</tt></i>:</span></td><td>the document pointer</td></tr><tr><td><span class="term"><i><tt>name</tt></i>:</span></td><td>the DTD name</td></tr><tr><td><span class="term"><i><tt>ExternalID</tt></i>:</span></td><td>the external (PUBLIC) ID</td></tr><tr><td><span class="term"><i><tt>SystemID</tt></i>:</span></td><td>the system ID</td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>a pointer to the new DTD structure</td></tr></tbody></table></div></div>
<hr/>
<div class="refsect2" lang="en"><h3><a name="xmlDOMWrapAdoptNode"/>xmlDOMWrapAdoptNode ()</h3><pre class="programlisting">int xmlDOMWrapAdoptNode (<a href="libxml2-tree.html#xmlDOMWrapCtxtPtr">xmlDOMWrapCtxtPtr</a> ctxt, <br/> <a href="libxml2-tree.html#xmlDocPtr">xmlDocPtr</a> sourceDoc, <br/> <a href="libxml2-tree.html#xmlNodePtr">xmlNodePtr</a> node, <br/> <a href="libxml2-tree.html#xmlDocPtr">xmlDocPtr</a> destDoc, <br/> <a href="libxml2-tree.html#xmlNodePtr">xmlNodePtr</a> destParent, <br/> int options)<br/>
-</pre><p>Ensures that ns-references point to @destDoc: either to elements-&gt;nsDef entries if @destParent is given, or to @destDoc-&gt;oldNs otherwise. If @destParent is given, it ensures that the tree is namespace wellformed by creating additional ns-decls where needed. Note that, since prefixes of already existent ns-decls can be shadowed by this process, it could break QNames in <a href="libxml2-SAX.html#attribute">attribute</a> values or element content. WARNING: This function is in a experimental state.</p>
-<div class="variablelist"><table border="0"><col align="left"/><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i>:</span></td><td>the optional context for custom processing</td></tr><tr><td><span class="term"><i><tt>sourceDoc</tt></i>:</span></td><td>the optional sourceDoc</td></tr><tr><td><span class="term"><i><tt>node</tt></i>:</span></td><td>the node to start with</td></tr><tr><td><span class="term"><i><tt>destDoc</tt></i>:</span></td><td>the destination doc</td></tr><tr><td><span class="term"><i><tt>destParent</tt></i>:</span></td><td>the optional new parent of @node in @destDoc</td></tr><tr><td><span class="term"><i><tt>options</tt></i>:</span></td><td>option flags</td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>0 if succeeded, -1 otherwise and on API/internal errors.</td></tr></tbody></table></div></div>
+</pre><p>References of out-of scope ns-decls are remapped to point to @destDoc: 1) If @destParent is given, then nsDef entries on element-nodes are used 2) If *no* @destParent is given, then @destDoc-&gt;oldNs entries are used This is the case when you have an unliked node and just want to move it to the context of If @destParent is given, it ensures that the tree is namespace wellformed by creating additional ns-decls where needed. Note that, since prefixes of already existent ns-decls can be shadowed by this process, it could break QNames in <a href="libxml2-SAX.html#attribute">attribute</a> values or element content. WARNING: This function is in a experimental state.</p>
+<div class="variablelist"><table border="0"><col align="left"/><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i>:</span></td><td>the optional context for custom processing</td></tr><tr><td><span class="term"><i><tt>sourceDoc</tt></i>:</span></td><td>the optional sourceDoc</td></tr><tr><td><span class="term"><i><tt>node</tt></i>:</span></td><td>the node to start with</td></tr><tr><td><span class="term"><i><tt>destDoc</tt></i>:</span></td><td>the destination doc</td></tr><tr><td><span class="term"><i><tt>destParent</tt></i>:</span></td><td>the optional new parent of @node in @destDoc</td></tr><tr><td><span class="term"><i><tt>options</tt></i>:</span></td><td>option flags</td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>0 if the operation succeeded, 1 if a node of unsupported type was given, 2 if a node of not yet supported type was given and -1 on API/internal errors.</td></tr></tbody></table></div></div>
+ <hr/>
+ <div class="refsect2" lang="en"><h3><a name="xmlDOMWrapCloneNode"/>xmlDOMWrapCloneNode ()</h3><pre class="programlisting">int xmlDOMWrapCloneNode (<a href="libxml2-tree.html#xmlDOMWrapCtxtPtr">xmlDOMWrapCtxtPtr</a> ctxt, <br/> <a href="libxml2-tree.html#xmlDocPtr">xmlDocPtr</a> sourceDoc, <br/> <a href="libxml2-tree.html#xmlNodePtr">xmlNodePtr</a> node, <br/> <a href="libxml2-tree.html#xmlNodePtr">xmlNodePtr</a> * resNode, <br/> <a href="libxml2-tree.html#xmlDocPtr">xmlDocPtr</a> destDoc, <br/> <a href="libxml2-tree.html#xmlNodePtr">xmlNodePtr</a> destParent, <br/> int deep, <br/> int options)<br/>
+</pre><p>References of out-of scope ns-decls are remapped to point to @destDoc: 1) If @destParent is given, then nsDef entries on element-nodes are used 2) If *no* @destParent is given, then @destDoc-&gt;oldNs entries are used This is the case when you have an unliked node and just want to move it to the context of If @destParent is given, it ensures that the tree is namespace wellformed by creating additional ns-decls where needed. Note that, since prefixes of already existent ns-decls can be shadowed by this process, it could break QNames in <a href="libxml2-SAX.html#attribute">attribute</a> values or element content. TODO: 1) Support dicts Optimize string adoption for equal or none dicts. 2) XInclude WARNING: This function is in a experimental state and should only be currently only be used to test it.</p>
+<div class="variablelist"><table border="0"><col align="left"/><tbody><tr><td><span class="term"><i><tt>ctxt</tt></i>:</span></td><td>the optional context for custom processing</td></tr><tr><td><span class="term"><i><tt>sourceDoc</tt></i>:</span></td><td>the optional sourceDoc</td></tr><tr><td><span class="term"><i><tt>node</tt></i>:</span></td><td>the node to start with</td></tr><tr><td><span class="term"><i><tt>resNode</tt></i>:</span></td><td>the clone of the given @node</td></tr><tr><td><span class="term"><i><tt>destDoc</tt></i>:</span></td><td>the destination doc</td></tr><tr><td><span class="term"><i><tt>destParent</tt></i>:</span></td><td>the optional new parent of @node in @destDoc</td></tr><tr><td><span class="term"><i><tt>deep</tt></i>:</span></td><td>descend into child if set</td></tr><tr><td><span class="term"><i><tt>options</tt></i>:</span></td><td>option flags</td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>0 if the operation succeeded, 1 if a node of unsupported (or not yet supported) type was given, -1 on API/internal errors.</td></tr></tbody></table></div></div>
<hr/>
<div class="refsect2" lang="en"><h3><a name="xmlDOMWrapFreeCtxt"/>xmlDOMWrapFreeCtxt ()</h3><pre class="programlisting">void xmlDOMWrapFreeCtxt (<a href="libxml2-tree.html#xmlDOMWrapCtxtPtr">xmlDOMWrapCtxtPtr</a> ctxt)<br/>
</pre><p>Frees the DOM-wrapper context.</p>
@@ -1409,12 +1414,12 @@ void <a href="#xmlFreeNsList">xmlFreeNsList</a> (<a href="libxml2-tree.html#xm
<div class="variablelist"><table border="0"><col align="left"/><tbody><tr><td><span class="term"><i><tt>node</tt></i>:</span></td><td>a node in the document</td></tr><tr><td><span class="term"><i><tt>ns</tt></i>:</span></td><td>a namespace pointer</td></tr></tbody></table></div></div>
<hr/>
<div class="refsect2" lang="en"><h3><a name="xmlSetNsProp"/>xmlSetNsProp ()</h3><pre class="programlisting"><a href="libxml2-tree.html#xmlAttrPtr">xmlAttrPtr</a> xmlSetNsProp (<a href="libxml2-tree.html#xmlNodePtr">xmlNodePtr</a> node, <br/> <a href="libxml2-tree.html#xmlNsPtr">xmlNsPtr</a> ns, <br/> const <a href="libxml2-xmlstring.html#xmlChar">xmlChar</a> * name, <br/> const <a href="libxml2-xmlstring.html#xmlChar">xmlChar</a> * value)<br/>
-</pre><p>Set (or reset) an <a href="libxml2-SAX.html#attribute">attribute</a> carried by a node. The ns structure must be in scope, this is not checked.</p>
+</pre><p>Set (or reset) an <a href="libxml2-SAX.html#attribute">attribute</a> carried by a node. The ns structure must be in scope, this is not checked</p>
<div class="variablelist"><table border="0"><col align="left"/><tbody><tr><td><span class="term"><i><tt>node</tt></i>:</span></td><td>the node</td></tr><tr><td><span class="term"><i><tt>ns</tt></i>:</span></td><td>the namespace definition</td></tr><tr><td><span class="term"><i><tt>name</tt></i>:</span></td><td>the <a href="libxml2-SAX.html#attribute">attribute</a> name</td></tr><tr><td><span class="term"><i><tt>value</tt></i>:</span></td><td>the <a href="libxml2-SAX.html#attribute">attribute</a> value</td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>the <a href="libxml2-SAX.html#attribute">attribute</a> pointer.</td></tr></tbody></table></div></div>
<hr/>
<div class="refsect2" lang="en"><h3><a name="xmlSetProp"/>xmlSetProp ()</h3><pre class="programlisting"><a href="libxml2-tree.html#xmlAttrPtr">xmlAttrPtr</a> xmlSetProp (<a href="libxml2-tree.html#xmlNodePtr">xmlNodePtr</a> node, <br/> const <a href="libxml2-xmlstring.html#xmlChar">xmlChar</a> * name, <br/> const <a href="libxml2-xmlstring.html#xmlChar">xmlChar</a> * value)<br/>
-</pre><p>Set (or reset) an <a href="libxml2-SAX.html#attribute">attribute</a> carried by a node.</p>
-<div class="variablelist"><table border="0"><col align="left"/><tbody><tr><td><span class="term"><i><tt>node</tt></i>:</span></td><td>the node</td></tr><tr><td><span class="term"><i><tt>name</tt></i>:</span></td><td>the <a href="libxml2-SAX.html#attribute">attribute</a> name</td></tr><tr><td><span class="term"><i><tt>value</tt></i>:</span></td><td>the <a href="libxml2-SAX.html#attribute">attribute</a> value</td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>the <a href="libxml2-SAX.html#attribute">attribute</a> pointer.</td></tr></tbody></table></div></div>
+</pre><p>Set (or reset) an <a href="libxml2-SAX.html#attribute">attribute</a> carried by a node. If @name has a prefix, then the corresponding namespace-binding will be used, if in scope; it is an error it there's no such ns-binding for the prefix in scope.</p>
+<div class="variablelist"><table border="0"><col align="left"/><tbody><tr><td><span class="term"><i><tt>node</tt></i>:</span></td><td>the node</td></tr><tr><td><span class="term"><i><tt>name</tt></i>:</span></td><td>the <a href="libxml2-SAX.html#attribute">attribute</a> name (a QName)</td></tr><tr><td><span class="term"><i><tt>value</tt></i>:</span></td><td>the <a href="libxml2-SAX.html#attribute">attribute</a> value</td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>the <a href="libxml2-SAX.html#attribute">attribute</a> pointer.</td></tr></tbody></table></div></div>
<hr/>
<div class="refsect2" lang="en"><h3><a name="xmlSetTreeDoc"/>xmlSetTreeDoc ()</h3><pre class="programlisting">void xmlSetTreeDoc (<a href="libxml2-tree.html#xmlNodePtr">xmlNodePtr</a> tree, <br/> <a href="libxml2-tree.html#xmlDocPtr">xmlDocPtr</a> doc)<br/>
</pre><p>update all nodes under the tree to point to the right document</p>
@@ -1453,7 +1458,7 @@ void <a href="#xmlFreeNsList">xmlFreeNsList</a> (<a href="libxml2-tree.html#xm
<div class="variablelist"><table border="0"><col align="left"/><tbody><tr><td><span class="term"><i><tt>node</tt></i>:</span></td><td>the node</td></tr><tr><td><span class="term"><i><tt>ns</tt></i>:</span></td><td>the namespace definition</td></tr><tr><td><span class="term"><i><tt>name</tt></i>:</span></td><td>the <a href="libxml2-SAX.html#attribute">attribute</a> name</td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>0 if successful, -1 if not found</td></tr></tbody></table></div></div>
<hr/>
<div class="refsect2" lang="en"><h3><a name="xmlUnsetProp"/>xmlUnsetProp ()</h3><pre class="programlisting">int xmlUnsetProp (<a href="libxml2-tree.html#xmlNodePtr">xmlNodePtr</a> node, <br/> const <a href="libxml2-xmlstring.html#xmlChar">xmlChar</a> * name)<br/>
-</pre><p>Remove an <a href="libxml2-SAX.html#attribute">attribute</a> carried by a node.</p>
+</pre><p>Remove an <a href="libxml2-SAX.html#attribute">attribute</a> carried by a node. This handles only attributes in no namespace.</p>
<div class="variablelist"><table border="0"><col align="left"/><tbody><tr><td><span class="term"><i><tt>node</tt></i>:</span></td><td>the node</td></tr><tr><td><span class="term"><i><tt>name</tt></i>:</span></td><td>the <a href="libxml2-SAX.html#attribute">attribute</a> name</td></tr><tr><td><span class="term"><i><tt>Returns</tt></i>:</span></td><td>0 if successful, -1 if not found</td></tr></tbody></table></div></div>
<hr/>
<div class="refsect2" lang="en"><h3><a name="xmlValidateNCName"/>xmlValidateNCName ()</h3><pre class="programlisting">int xmlValidateNCName (const <a href="libxml2-xmlstring.html#xmlChar">xmlChar</a> * value, <br/> int space)<br/>