reference/dom/domnode/replacechild.xml
4f5e2b22575131fa5e9c3004b1c874e1acb06573
...
...
@@ -1,6 +1,6 @@
1
1
<?xml version="1.0" encoding="utf-8"?>
2
2
<!-- $Revision$ -->
3
-
<refentry xml:id='domnode.replacechild' xmlns="http://docbook.org/ns/docbook">
3
+
<refentry xml:id="domnode.replacechild" xmlns="http://docbook.org/ns/docbook">
4
4
<refnamediv>
5
5
<refname>DOMNode::replaceChild</refname>
6
6
<refpurpose>
...
...
@@ -9,14 +9,14 @@
9
9
</refnamediv>
10
10
<refsect1 role="description">
11
11
&reftitle.description;
12
-
<methodsynopsis>
13
-
<modifier>public</modifier> <type>DOMNode</type><methodname>DOMNode::replaceChild</methodname>
14
-
<methodparam><type>DOMNode</type><parameter>newnode</parameter></methodparam>
15
-
<methodparam><type>DOMNode</type><parameter>oldnode</parameter></methodparam>
12
+
<methodsynopsis role="DOMNode">
13
+
<modifier>public</modifier> <type class="union"><type>DOMNode</type><type>false</type></type><methodname>DOMNode::replaceChild</methodname>
14
+
<methodparam><type>DOMNode</type><parameter>node</parameter></methodparam>
15
+
<methodparam><type>DOMNode</type><parameter>child</parameter></methodparam>
16
16
</methodsynopsis>
17
17
<para>
18
-
This function replaces the child <parameter>oldnode</parameter>
19
-
with the passed new node. If the <parameter>newnode</parameter> is already a child it
18
+
This function replaces the child <parameter>child</parameter>
19
+
with the passed new node. If the <parameter>node</parameter> is already a child it
20
20
will not be added a second time. If the replacement succeeds the
21
21
old node is returned.
22
22
</para>
...
...
@@ -26,17 +26,17 @@
26
26
<para>
27
27
<variablelist>
28
28
<varlistentry>
29
-
<term><parameter>newnode</parameter></term>
29
+
<term><parameter>node</parameter></term>
30
30
<listitem>
31
31
<para>
32
32
The new node. It must be a member of the target document, i.e.
33
-
created by one of the DOMDocument->createXXX() methods or imported in
34
-
the document by <xref linkend='domdocument.importnode' />.
33
+
created by one of the DOMDocument-&gt;createXXX() methods or imported in
34
+
the document by <xref linkend="domdocument.importnode"/>.
35
35
</para>
36
36
</listitem>
37
37
</varlistentry>
38
38
<varlistentry>
39
-
<term><parameter>oldnode</parameter></term>
39
+
<term><parameter>child</parameter></term>
40
40
<listitem>
41
41
<para>
42
42
The old node.
...
...
@@ -70,7 +70,7 @@
70
70
<listitem>
71
71
<para>
72
72
Raised if this node is of a type that does not allow children of the
73
-
type of the <parameter>newnode</parameter> node, or if the node to
73
+
type of the <parameter>node</parameter> node, or if the node to
74
74
put in is one of this node's ancestors or this node itself.
75
75
</para>
76
76
</listitem>
...
...
@@ -79,7 +79,7 @@
79
79
<term><constant>DOM_WRONG_DOCUMENT_ERR</constant></term>
80
80
<listitem>
81
81
<para>
82
-
Raised if <parameter>newnode</parameter> was created from a different
82
+
Raised if <parameter>node</parameter> was created from a different
83
83
document than the one that created this node.
84
84
</para>
85
85
</listitem>
...
...
@@ -88,7 +88,7 @@
88
88
<term><constant>DOM_NOT_FOUND</constant></term>
89
89
<listitem>
90
90
<para>
91
-
Raised if <parameter>oldnode</parameter> is not a child of this node.
91
+
Raised if <parameter>child</parameter> is not a child of this node.
92
92
</para>
93
93
</listitem>
94
94
</varlistentry>
...
...
@@ -99,13 +99,13 @@
99
99
&reftitle.seealso;
100
100
<para>
101
101
<simplelist>
102
+
<member><methodname>DOMChildNode::replaceWith</methodname></member>
102
103
<member><methodname>DOMNode::appendChild</methodname></member>
103
104
<member><methodname>DOMNode::removeChild</methodname></member>
104
105
</simplelist>
105
106
</para>
106
107
</refsect1>
107
108
</refentry>
108
-

109
109
<!-- Keep this comment at the end of the file
110
110
Local variables:
111
111
mode: sgml
112
112