1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>Xerces-C++: DOMDocumentFragment Class Reference</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
<link href="tabs.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.5.6 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main Page</span></a></li>
<li><a href="pages.html"><span>Related Pages</span></a></li>
<li class="current"><a href="classes.html"><span>Classes</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="classes.html"><span>Alphabetical List</span></a></li>
<li><a href="annotated.html"><span>Class List</span></a></li>
<li><a href="hierarchy.html"><span>Class Hierarchy</span></a></li>
<li><a href="functions.html"><span>Class Members</span></a></li>
</ul>
</div>
</div>
<div class="contents">
<h1>DOMDocumentFragment Class Reference</h1><!-- doxytag: class="DOMDocumentFragment" --><!-- doxytag: inherits="DOMNode" --><a class="el" href="classDOMDocumentFragment.html" title="DOMDocumentFragment is a "lightweight" or "minimal" DOMDocument...">DOMDocumentFragment</a> is a "lightweight" or "minimal" <a class="el" href="classDOMDocument.html" title="The DOMDocument interface represents the entire XML document.">DOMDocument</a> object.
<a href="#_details">More...</a>
<p>
<div class="dynheader">
Inheritance diagram for DOMDocumentFragment:</div>
<div class="dynsection">
<p><center><img src="classDOMDocumentFragment.png" usemap="#DOMDocumentFragment_map" border="0" alt=""></center>
<map name="DOMDocumentFragment_map">
<area href="classDOMNode.html" alt="DOMNode" shape="rect" coords="0,0,151,24">
</map>
</div>
<p>
<a href="classDOMDocumentFragment-members.html">List of all members.</a><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr>
<tr><td colspan="2"><div class="groupHeader">Destructor</div></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">virtual </td><td class="memItemRight" valign="bottom"><a class="el" href="classDOMDocumentFragment.html#32bdd0fd37cfcc9783b9be8a1d1f61e2">~DOMDocumentFragment</a> ()</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Destructor. <a href="#32bdd0fd37cfcc9783b9be8a1d1f61e2"></a><br></td></tr>
<tr><td colspan="2"><br><h2>Protected Member Functions</h2></td></tr>
<tr><td colspan="2"><div class="groupHeader">Hidden constructors</div></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="classDOMDocumentFragment.html#6377889dbf64a3e1601de740c2149f14">DOMDocumentFragment</a> ()</td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
<a class="el" href="classDOMDocumentFragment.html" title="DOMDocumentFragment is a "lightweight" or "minimal" DOMDocument...">DOMDocumentFragment</a> is a "lightweight" or "minimal" <a class="el" href="classDOMDocument.html" title="The DOMDocument interface represents the entire XML document.">DOMDocument</a> object.
<p>
It is very common to want to be able to extract a portion of a document's tree or to create a new fragment of a document. Imagine implementing a user command like cut or rearranging a document by moving fragments around. It is desirable to have an object which can hold such fragments and it is quite natural to use a <a class="el" href="classDOMNode.html" title="The DOMNode interface is the primary datatype for the entire Document Object Model...">DOMNode</a> for this purpose. While it is true that a <code><a class="el" href="classDOMDocument.html" title="The DOMDocument interface represents the entire XML document.">DOMDocument</a></code> object could fulfill this role, a <code><a class="el" href="classDOMDocument.html" title="The DOMDocument interface represents the entire XML document.">DOMDocument</a></code> object can potentially be a heavyweight object, depending on the underlying implementation. What is really needed for this is a very lightweight object. <code><a class="el" href="classDOMDocumentFragment.html" title="DOMDocumentFragment is a "lightweight" or "minimal" DOMDocument...">DOMDocumentFragment</a></code> is such an object. <p>
Furthermore, various operations -- such as inserting nodes as children of another <code><a class="el" href="classDOMNode.html" title="The DOMNode interface is the primary datatype for the entire Document Object Model...">DOMNode</a></code> -- may take <code><a class="el" href="classDOMDocumentFragment.html" title="DOMDocumentFragment is a "lightweight" or "minimal" DOMDocument...">DOMDocumentFragment</a></code> objects as arguments; this results in all the child nodes of the <code><a class="el" href="classDOMDocumentFragment.html" title="DOMDocumentFragment is a "lightweight" or "minimal" DOMDocument...">DOMDocumentFragment</a></code> being moved to the child list of this node. <p>
The children of a <code><a class="el" href="classDOMDocumentFragment.html" title="DOMDocumentFragment is a "lightweight" or "minimal" DOMDocument...">DOMDocumentFragment</a></code> node are zero or more nodes representing the tops of any sub-trees defining the structure of the document. <code><a class="el" href="classDOMDocumentFragment.html" title="DOMDocumentFragment is a "lightweight" or "minimal" DOMDocument...">DOMDocumentFragment</a></code> nodes do not need to be well-formed XML documents (although they do need to follow the rules imposed upon well-formed XML parsed entities, which can have multiple top nodes). For example, a <code><a class="el" href="classDOMDocumentFragment.html" title="DOMDocumentFragment is a "lightweight" or "minimal" DOMDocument...">DOMDocumentFragment</a></code> might have only one child and that child node could be a <code><a class="el" href="classDOMText.html" title="The DOMText interface inherits from DOMCharacterData and represents the textual content...">DOMText</a></code> node. Such a structure model represents neither an HTML document nor a well-formed XML document. <p>
When a <code><a class="el" href="classDOMDocumentFragment.html" title="DOMDocumentFragment is a "lightweight" or "minimal" DOMDocument...">DOMDocumentFragment</a></code> is inserted into a <code><a class="el" href="classDOMDocument.html" title="The DOMDocument interface represents the entire XML document.">DOMDocument</a></code> (or indeed any other <code><a class="el" href="classDOMNode.html" title="The DOMNode interface is the primary datatype for the entire Document Object Model...">DOMNode</a></code> that may take children) the children of the <code><a class="el" href="classDOMDocumentFragment.html" title="DOMDocumentFragment is a "lightweight" or "minimal" DOMDocument...">DOMDocumentFragment</a></code> and not the <code><a class="el" href="classDOMDocumentFragment.html" title="DOMDocumentFragment is a "lightweight" or "minimal" DOMDocument...">DOMDocumentFragment</a></code> itself are inserted into the <code><a class="el" href="classDOMNode.html" title="The DOMNode interface is the primary datatype for the entire Document Object Model...">DOMNode</a></code>. This makes the <code><a class="el" href="classDOMDocumentFragment.html" title="DOMDocumentFragment is a "lightweight" or "minimal" DOMDocument...">DOMDocumentFragment</a></code> very useful when the user wishes to create nodes that are siblings; the <code><a class="el" href="classDOMDocumentFragment.html" title="DOMDocumentFragment is a "lightweight" or "minimal" DOMDocument...">DOMDocumentFragment</a></code> acts as the parent of these nodes so that the user can use the standard methods from the <code><a class="el" href="classDOMNode.html" title="The DOMNode interface is the primary datatype for the entire Document Object Model...">DOMNode</a></code> interface, such as <code><a class="el" href="classDOMNode.html#6b31cf8cc701c8685a00f46f05efcffd" title="Inserts the node newChild before the existing child node refChild.">insertBefore()</a></code> and <code><a class="el" href="classDOMNode.html#504731160f9bfff5bb9cc64afabf0e2f" title="Adds the node newChild to the end of the list of children of this node.">appendChild()</a></code>.<p>
<dl class="since" compact><dt><b>Since:</b></dt><dd>DOM Level 1 </dd></dl>
<hr><h2>Constructor & Destructor Documentation</h2>
<a class="anchor" name="6377889dbf64a3e1601de740c2149f14"></a><!-- doxytag: member="DOMDocumentFragment::DOMDocumentFragment" ref="6377889dbf64a3e1601de740c2149f14" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">DOMDocumentFragment::DOMDocumentFragment </td>
<td>(</td>
<td class="paramname"> </td>
<td> ) </td>
<td><code> [protected]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
</div>
</div><p>
<a class="anchor" name="32bdd0fd37cfcc9783b9be8a1d1f61e2"></a><!-- doxytag: member="DOMDocumentFragment::~DOMDocumentFragment" ref="32bdd0fd37cfcc9783b9be8a1d1f61e2" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">virtual DOMDocumentFragment::~DOMDocumentFragment </td>
<td>(</td>
<td class="paramname"> </td>
<td> ) </td>
<td><code> [virtual]</code></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Destructor.
<p>
</div>
</div><p>
<hr>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="DOMDocumentFragment_8hpp-source.html">DOMDocumentFragment.hpp</a></ul>
</div>
<hr size="1"><address style="text-align: right;"><small>Generated on Wed Apr 21 17:55:49 2010 for Xerces-C++ by
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.6 </small></address>
</body>
</html>
|