libxml-ruby 0.7.0-x86-mswin32-60 → 0.8.0-x86-mswin32-60

Sign up to get free protection for your applications and to get access to all the features.
Files changed (188) hide show
  1. data/CHANGES +24 -1
  2. data/README +48 -3
  3. data/benchmark/depixelate.rb +632 -0
  4. data/benchmark/hamlet.xml +9055 -0
  5. data/benchmark/sock_entries.xml +507 -0
  6. data/benchmark/throughput.rb +39 -0
  7. data/benchmark/xml_benchmarks.rb +222 -0
  8. data/doc/classes/LibXML.html +237 -0
  9. data/doc/classes/LibXML/XML.html +178 -0
  10. data/doc/classes/{XML → LibXML/XML}/Attr.html +213 -182
  11. data/doc/classes/{XML → LibXML/XML}/Attributes.html +126 -54
  12. data/doc/classes/{XML → LibXML/XML}/Document.html +299 -297
  13. data/doc/classes/{XML → LibXML/XML}/Dtd.html +10 -10
  14. data/doc/classes/{XML/XInclude → LibXML/XML}/Error.html +4 -4
  15. data/doc/classes/{XML → LibXML/XML}/HTMLParser.html +40 -40
  16. data/doc/classes/{XML → LibXML/XML}/InputCallbacks.html +10 -10
  17. data/doc/classes/{XML → LibXML/XML}/NS.html +46 -46
  18. data/doc/classes/{XML → LibXML/XML}/Node.html +935 -788
  19. data/doc/classes/LibXML/XML/Node/FailedModify.html +111 -0
  20. data/doc/classes/{XML → LibXML/XML}/Node/Set.html +69 -68
  21. data/doc/classes/{XML → LibXML/XML}/Node/SetNamespace.html +4 -4
  22. data/doc/classes/{XML/Node/FailedModify.html → LibXML/XML/Node/UnknownType.html} +4 -4
  23. data/doc/classes/{XML → LibXML/XML}/Parser.html +426 -389
  24. data/doc/classes/{XML → LibXML/XML}/Parser/Context.html +208 -208
  25. data/doc/classes/{XML → LibXML/XML}/Parser/ParseError.html +4 -4
  26. data/doc/classes/{XML → LibXML/XML}/Reader.html +288 -287
  27. data/doc/classes/{XML → LibXML/XML}/SaxParser.html +52 -52
  28. data/doc/classes/{XML/XPath/Context.html → LibXML/XML/Schema.html} +60 -32
  29. data/doc/classes/{XML → LibXML/XML}/State.html +4 -4
  30. data/doc/classes/{XML/Node/UnknownType.html → LibXML/XML/Tree.html} +5 -5
  31. data/doc/classes/{XML → LibXML/XML}/XInclude.html +5 -5
  32. data/doc/classes/{XML → LibXML/XML/XInclude}/Error.html +5 -5
  33. data/doc/classes/{XML → LibXML/XML}/XMLParserOptions.html +5 -5
  34. data/doc/classes/{XML → LibXML/XML}/XPath.html +23 -64
  35. data/doc/classes/LibXML/XML/XPath/Context.html +403 -0
  36. data/doc/classes/{XML/XPointer/Context → LibXML/XML/XPath}/InvalidPath.html +4 -4
  37. data/doc/classes/LibXML/XML/XPath/Object.html +623 -0
  38. data/doc/classes/{XML → LibXML/XML}/XPointer.html +12 -12
  39. data/doc/classes/{XML → LibXML/XML}/XPointer/Context.html +5 -5
  40. data/doc/classes/{XML/XPath → LibXML/XML/XPointer/Context}/InvalidPath.html +5 -5
  41. data/doc/classes/{XML → LibXML/XML}/XPointer/InvalidExpression.html +4 -4
  42. data/doc/classes/XML.html +17 -123
  43. data/doc/created.rid +1 -1
  44. data/doc/files/CHANGES.html +49 -25
  45. data/doc/files/LICENSE.html +1 -1
  46. data/doc/files/README.html +79 -4
  47. data/doc/files/VERSION.html +2 -2
  48. data/doc/files/ext/libxml/cbg_c.html +1 -1
  49. data/doc/files/ext/libxml/libxml_c.html +1 -1
  50. data/doc/files/ext/libxml/ruby_xml_attr_c.html +1 -1
  51. data/doc/files/ext/libxml/ruby_xml_attributes_c.html +1 -1
  52. data/doc/files/ext/libxml/ruby_xml_document_c.html +1 -1
  53. data/doc/files/ext/libxml/ruby_xml_dtd_c.html +1 -1
  54. data/doc/files/ext/libxml/ruby_xml_html_parser_c.html +1 -1
  55. data/doc/files/ext/libxml/ruby_xml_input_cbg_c.html +1 -1
  56. data/doc/files/ext/libxml/ruby_xml_node_c.html +1 -1
  57. data/doc/files/ext/libxml/ruby_xml_node_set_c.html +1 -1
  58. data/doc/files/ext/libxml/ruby_xml_ns_c.html +1 -1
  59. data/doc/files/ext/libxml/ruby_xml_parser_c.html +1 -1
  60. data/doc/files/ext/libxml/ruby_xml_parser_context_c.html +1 -1
  61. data/doc/files/ext/libxml/ruby_xml_reader_c.html +1 -1
  62. data/doc/files/ext/libxml/ruby_xml_sax_parser_c.html +1 -1
  63. data/doc/files/ext/libxml/ruby_xml_schema_c.html +1 -1
  64. data/doc/files/ext/libxml/ruby_xml_state_c.html +1 -1
  65. data/doc/files/ext/libxml/ruby_xml_xinclude_c.html +1 -1
  66. data/doc/files/ext/libxml/ruby_xml_xpath_c.html +1 -1
  67. data/doc/files/ext/libxml/ruby_xml_xpath_context_c.html +1 -1
  68. data/doc/files/ext/libxml/ruby_xml_xpath_object_c.html +1 -1
  69. data/doc/files/ext/libxml/ruby_xml_xpointer_c.html +1 -1
  70. data/doc/files/ext/libxml/ruby_xml_xpointer_context_c.html +1 -1
  71. data/doc/files/lib/libxml/attr_rb.html +108 -0
  72. data/doc/files/lib/libxml/attributes_rb.html +108 -0
  73. data/doc/files/lib/libxml/document_rb.html +108 -0
  74. data/doc/files/lib/libxml/node_rb.html +108 -0
  75. data/doc/files/lib/libxml/node_set_rb.html +108 -0
  76. data/doc/files/lib/libxml/parser_options_rb.html +107 -0
  77. data/doc/files/{ext/libxml/ruby_xml_tree_c.html → lib/libxml/parser_rb.html} +4 -4
  78. data/doc/files/lib/libxml/properties_rb.html +108 -0
  79. data/doc/files/lib/libxml/tree_rb.html +107 -0
  80. data/doc/files/lib/libxml_rb.html +12 -3
  81. data/doc/fr_class_index.html +34 -32
  82. data/doc/fr_file_index.html +9 -1
  83. data/doc/fr_method_index.html +362 -347
  84. data/ext/libxml/cbg.c +76 -76
  85. data/ext/libxml/libxml.c +4 -3
  86. data/ext/libxml/ruby_libxml.h +1 -1
  87. data/ext/libxml/ruby_xml_attr.c +4 -3
  88. data/ext/libxml/ruby_xml_attr.h +16 -16
  89. data/ext/libxml/ruby_xml_attributes.c +267 -266
  90. data/ext/libxml/ruby_xml_attributes.h +17 -17
  91. data/ext/libxml/ruby_xml_document.c +30 -59
  92. data/ext/libxml/ruby_xml_document.h +27 -27
  93. data/ext/libxml/ruby_xml_dtd.c +2 -1
  94. data/ext/libxml/ruby_xml_dtd.h +17 -17
  95. data/ext/libxml/ruby_xml_html_parser.c +3 -2
  96. data/ext/libxml/ruby_xml_html_parser.h +29 -29
  97. data/ext/libxml/ruby_xml_input_cbg.c +2 -1
  98. data/ext/libxml/ruby_xml_input_cbg.h +20 -20
  99. data/ext/libxml/ruby_xml_node.c +127 -470
  100. data/ext/libxml/ruby_xml_node.h +17 -17
  101. data/ext/libxml/ruby_xml_node_set.c +5 -4
  102. data/ext/libxml/ruby_xml_node_set.h +20 -20
  103. data/ext/libxml/ruby_xml_ns.c +3 -2
  104. data/ext/libxml/ruby_xml_ns.h +12 -12
  105. data/ext/libxml/ruby_xml_parser.c +20 -48
  106. data/ext/libxml/ruby_xml_parser.h +31 -31
  107. data/ext/libxml/ruby_xml_parser_context.c +3 -2
  108. data/ext/libxml/ruby_xml_parser_context.h +20 -20
  109. data/ext/libxml/ruby_xml_reader.c +2 -1
  110. data/ext/libxml/ruby_xml_sax_parser.c +3 -2
  111. data/ext/libxml/ruby_xml_sax_parser.h +56 -56
  112. data/ext/libxml/ruby_xml_schema.c +6 -0
  113. data/ext/libxml/ruby_xml_schema.h +16 -16
  114. data/ext/libxml/ruby_xml_state.c +13 -12
  115. data/ext/libxml/ruby_xml_state.h +1 -1
  116. data/ext/libxml/ruby_xml_xinclude.c +3 -2
  117. data/ext/libxml/ruby_xml_xinclude.h +13 -13
  118. data/ext/libxml/ruby_xml_xpath.c +35 -228
  119. data/ext/libxml/ruby_xml_xpath.h +22 -23
  120. data/ext/libxml/ruby_xml_xpath_context.c +223 -62
  121. data/ext/libxml/ruby_xml_xpath_context.h +15 -20
  122. data/ext/libxml/ruby_xml_xpath_object.c +63 -19
  123. data/ext/libxml/ruby_xml_xpointer.c +19 -15
  124. data/ext/libxml/ruby_xml_xpointer.h +27 -27
  125. data/ext/libxml/ruby_xml_xpointer_context.c +3 -2
  126. data/ext/libxml/ruby_xml_xpointer_context.h +18 -18
  127. data/ext/libxml/version.h +9 -9
  128. data/lib/libxml.rb +16 -128
  129. data/lib/libxml/attr.rb +45 -0
  130. data/lib/libxml/attributes.rb +15 -0
  131. data/lib/libxml/document.rb +54 -0
  132. data/lib/libxml/node.rb +132 -0
  133. data/lib/libxml/node_set.rb +27 -0
  134. data/lib/libxml/parser.rb +42 -0
  135. data/lib/libxml/parser_options.rb +25 -0
  136. data/lib/libxml/properties.rb +19 -0
  137. data/lib/libxml/tree.rb +29 -0
  138. data/lib/libxml_ruby.so +0 -0
  139. data/mingw/libxml_ruby.so +0 -0
  140. data/{work/task/setup → setup.rb} +1585 -1616
  141. data/test/gc.log +0 -0
  142. data/test/model/books.xml +147 -0
  143. data/{work/test/runner.rb → test/model/default_validation_bug.rb} +0 -0
  144. data/test/model/merge_bug_data.xml +58 -0
  145. data/test/model/rubynet.xml +78 -0
  146. data/test/model/rubynet_project +1 -0
  147. data/test/model/saxtest.xml +5 -0
  148. data/test/model/shiporder.xml +23 -0
  149. data/test/model/shiporder.xsd +31 -0
  150. data/test/model/simple.xml +7 -0
  151. data/test/model/soap.xml +27 -0
  152. data/test/model/xinclude.xml +5 -0
  153. data/test/tc_deprecated_require.rb +13 -0
  154. data/test/tc_xml_document.rb +57 -16
  155. data/test/tc_xml_document_write.rb +125 -10
  156. data/test/tc_xml_dtd.rb +22 -1
  157. data/test/tc_xml_node.rb +13 -0
  158. data/test/tc_xml_node_edit.rb +1 -1
  159. data/test/tc_xml_node_xlink.rb +1 -1
  160. data/test/tc_xml_parser.rb +64 -7
  161. data/test/tc_xml_properties.rb +42 -0
  162. data/test/tc_xml_reader.rb +4 -4
  163. data/test/tc_xml_sax_parser.rb +50 -50
  164. data/test/tc_xml_schema.rb +2 -2
  165. data/test/tc_xml_traversal.rb +220 -0
  166. data/test/tc_xml_xinclude.rb +12 -15
  167. data/test/tc_xml_xpath.rb +74 -6
  168. data/test/tc_xml_xpath_context.rb +72 -0
  169. data/test/test_suite.rb +6 -4
  170. data/vc/libxml_ruby.vcproj +1 -9
  171. metadata +92 -65
  172. data/doc/classes/XML/SiblingEnum.html +0 -142
  173. data/doc/classes/XML/Tree.html +0 -224
  174. data/doc/classes/XML/XPath/Object.html +0 -439
  175. data/ext/libxml/ruby_xml_tree.c +0 -43
  176. data/ext/libxml/ruby_xml_tree.h +0 -12
  177. data/test/ets_copy_bug2.rb +0 -21
  178. data/test/tc_xml_document_write2.rb +0 -54
  179. data/test/tc_xml_document_write3.rb +0 -96
  180. data/test/tc_xml_sax_parser2.rb +0 -51
  181. data/work/Rakefile +0 -247
  182. data/work/task/make +0 -26
  183. data/work/task/memory +0 -37
  184. data/work/task/rdoc +0 -39
  185. data/work/task/test +0 -29
  186. data/work/test/ets_runner.rb +0 -33
  187. data/work/test/libxml_test.rb +0 -3
  188. data/work/test/runner_ets.rb +0 -33
@@ -5,10 +5,10 @@
5
5
 
6
6
  <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
7
7
  <head>
8
- <title>Class: XML::Attributes</title>
8
+ <title>Class: LibXML::XML::Attributes</title>
9
9
  <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
10
  <meta http-equiv="Content-Script-Type" content="text/javascript" />
11
- <link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
11
+ <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
12
12
  <script type="text/javascript">
13
13
  // <![CDATA[
14
14
 
@@ -50,14 +50,22 @@
50
50
  <table class="header-table">
51
51
  <tr class="top-aligned-row">
52
52
  <td><strong>Class</strong></td>
53
- <td class="class-name-in-header">XML::Attributes</td>
53
+ <td class="class-name-in-header">LibXML::XML::Attributes</td>
54
54
  </tr>
55
55
  <tr class="top-aligned-row">
56
56
  <td><strong>In:</strong></td>
57
57
  <td>
58
- <a href="../../files/ext/libxml/libxml_c.html">
58
+ <a href="../../../files/ext/libxml/libxml_c.html">
59
59
  ext/libxml/libxml.c
60
60
  </a>
61
+ <br />
62
+ <a href="../../../files/lib/libxml/attributes_rb.html">
63
+ lib/libxml/attributes.rb
64
+ </a>
65
+ <br />
66
+ <a href="../../../files/lib/libxml/properties_rb.html">
67
+ lib/libxml/properties.rb
68
+ </a>
61
69
  <br />
62
70
  </td>
63
71
  </tr>
@@ -119,14 +127,17 @@ To access a namespaced attribute:
119
127
  <h3 class="section-bar">Methods</h3>
120
128
 
121
129
  <div class="name-list">
122
- <a href="#M000207">[]</a>&nbsp;&nbsp;
123
- <a href="#M000208">[]=</a>&nbsp;&nbsp;
124
- <a href="#M000209">each</a>&nbsp;&nbsp;
125
- <a href="#M000211">first</a>&nbsp;&nbsp;
126
- <a href="#M000205">get_attribute</a>&nbsp;&nbsp;
127
- <a href="#M000206">get_attribute_ns</a>&nbsp;&nbsp;
128
- <a href="#M000210">length</a>&nbsp;&nbsp;
129
- <a href="#M000204">node</a>&nbsp;&nbsp;
130
+ <a href="#M000229">[]</a>&nbsp;&nbsp;
131
+ <a href="#M000230">[]=</a>&nbsp;&nbsp;
132
+ <a href="#M000231">each</a>&nbsp;&nbsp;
133
+ <a href="#M000235">each_attr</a>&nbsp;&nbsp;
134
+ <a href="#M000236">each_sibling</a>&nbsp;&nbsp;
135
+ <a href="#M000233">first</a>&nbsp;&nbsp;
136
+ <a href="#M000227">get_attribute</a>&nbsp;&nbsp;
137
+ <a href="#M000228">get_attribute_ns</a>&nbsp;&nbsp;
138
+ <a href="#M000232">length</a>&nbsp;&nbsp;
139
+ <a href="#M000226">node</a>&nbsp;&nbsp;
140
+ <a href="#M000234">to_h</a>&nbsp;&nbsp;
130
141
  </div>
131
142
  </div>
132
143
 
@@ -134,6 +145,13 @@ To access a namespaced attribute:
134
145
 
135
146
 
136
147
  <!-- if includes -->
148
+ <div id="includes">
149
+ <h3 class="section-bar">Included Modules</h3>
150
+
151
+ <div id="includes-list">
152
+ <span class="include-name">Enumerable</span>
153
+ </div>
154
+ </div>
137
155
 
138
156
  <div id="section">
139
157
 
@@ -148,11 +166,11 @@ To access a namespaced attribute:
148
166
  <div id="methods">
149
167
  <h3 class="section-bar">Public Instance methods</h3>
150
168
 
151
- <div id="method-M000207" class="method-detail">
152
- <a name="M000207"></a>
169
+ <div id="method-M000229" class="method-detail">
170
+ <a name="M000229"></a>
153
171
 
154
172
  <div class="method-heading">
155
- <a href="#M000207" class="method-signature">
173
+ <a href="#M000229" class="method-signature">
156
174
  <span class="method-name">attributes["name"] &rarr; String<br />
157
175
  </span>
158
176
  </a>
@@ -161,7 +179,7 @@ To access a namespaced attribute:
161
179
  <div class="method-description">
162
180
  <p>
163
181
  Fetches an attribute value. If you want to access the underlying Attribute
164
- itself use <a href="Attributes.html#M000205">get_attribute</a>.
182
+ itself use <a href="Attributes.html#M000227">get_attribute</a>.
165
183
  </p>
166
184
  <p>
167
185
  name: The name of the attribute, not including any namespaces.
@@ -170,8 +188,8 @@ name: The name of the attribute, not including any namespaces.
170
188
  doc.root.attributes['att'] -&gt; 'some value'
171
189
  </pre>
172
190
  <p><a class="source-toggle" href="#"
173
- onclick="toggleCode('M000207-source');return false;">[Source]</a></p>
174
- <div class="method-source-code" id="M000207-source">
191
+ onclick="toggleCode('M000229-source');return false;">[Source]</a></p>
192
+ <div class="method-source-code" id="M000229-source">
175
193
  <pre>
176
194
  /*
177
195
  * call-seq:
@@ -192,11 +210,11 @@ ruby_xml_attributes_attribute_get(VALUE self, VALUE name) {
192
210
  </div>
193
211
  </div>
194
212
 
195
- <div id="method-M000208" class="method-detail">
196
- <a name="M000208"></a>
213
+ <div id="method-M000230" class="method-detail">
214
+ <a name="M000230"></a>
197
215
 
198
216
  <div class="method-heading">
199
- <a href="#M000208" class="method-signature">
217
+ <a href="#M000230" class="method-signature">
200
218
  <span class="method-name">attributes["name"] = "value"<br />
201
219
  </span>
202
220
  </a>
@@ -205,7 +223,7 @@ ruby_xml_attributes_attribute_get(VALUE self, VALUE name) {
205
223
  <div class="method-description">
206
224
  <p>
207
225
  Sets an attribute value. If you want to get the Attribute itself, use <a
208
- href="Attributes.html#M000205">get_attribute</a>.
226
+ href="Attributes.html#M000227">get_attribute</a>.
209
227
  </p>
210
228
  <p>
211
229
  name: The name of the attribute, not including any namespaces. value: The
@@ -215,8 +233,8 @@ new value of the namespace.
215
233
  doc.root.attributes['att'] = 'some value'
216
234
  </pre>
217
235
  <p><a class="source-toggle" href="#"
218
- onclick="toggleCode('M000208-source');return false;">[Source]</a></p>
219
- <div class="method-source-code" id="M000208-source">
236
+ onclick="toggleCode('M000230-source');return false;">[Source]</a></p>
237
+ <div class="method-source-code" id="M000230-source">
220
238
  <pre>
221
239
  /*
222
240
  * call-seq:
@@ -238,11 +256,11 @@ ruby_xml_attributes_attribute_set(VALUE self, VALUE name, VALUE value) {
238
256
  </div>
239
257
  </div>
240
258
 
241
- <div id="method-M000209" class="method-detail">
242
- <a name="M000209"></a>
259
+ <div id="method-M000231" class="method-detail">
260
+ <a name="M000231"></a>
243
261
 
244
262
  <div class="method-heading">
245
- <a href="#M000209" class="method-signature">
263
+ <a href="#M000231" class="method-signature">
246
264
  <span class="method-name">attributes.each {block} &rarr; XML::Attr<br />
247
265
  </span>
248
266
  </a>
@@ -256,8 +274,8 @@ Iterates over each attribute.
256
274
  doc.root.attributes.each {|attribute| puts attribute.name}
257
275
  </pre>
258
276
  <p><a class="source-toggle" href="#"
259
- onclick="toggleCode('M000209-source');return false;">[Source]</a></p>
260
- <div class="method-source-code" id="M000209-source">
277
+ onclick="toggleCode('M000231-source');return false;">[Source]</a></p>
278
+ <div class="method-source-code" id="M000231-source">
261
279
  <pre>
262
280
  /*
263
281
  * call-seq:
@@ -275,11 +293,39 @@ ruby_xml_attributes_each(VALUE self) {
275
293
  </div>
276
294
  </div>
277
295
 
278
- <div id="method-M000211" class="method-detail">
279
- <a name="M000211"></a>
296
+ <div id="method-M000235" class="method-detail">
297
+ <a name="M000235"></a>
298
+
299
+ <div class="method-heading">
300
+ <span class="method-name">each_attr</span><span class="method-args">()</span>
301
+ </div>
302
+
303
+ <div class="method-description">
304
+ <p>
305
+ Alias for <a href="Attributes.html#M000231">each</a>
306
+ </p>
307
+ </div>
308
+ </div>
309
+
310
+ <div id="method-M000236" class="method-detail">
311
+ <a name="M000236"></a>
312
+
313
+ <div class="method-heading">
314
+ <span class="method-name">each_sibling</span><span class="method-args">()</span>
315
+ </div>
316
+
317
+ <div class="method-description">
318
+ <p>
319
+ Alias for <a href="Attributes.html#M000231">each</a>
320
+ </p>
321
+ </div>
322
+ </div>
323
+
324
+ <div id="method-M000233" class="method-detail">
325
+ <a name="M000233"></a>
280
326
 
281
327
  <div class="method-heading">
282
- <a href="#M000211" class="method-signature">
328
+ <a href="#M000233" class="method-signature">
283
329
  <span class="method-name">attributes.first &rarr; XML::Attr<br />
284
330
  </span>
285
331
  </a>
@@ -293,8 +339,8 @@ Returns the first attribute.
293
339
  doc.root.attributes.first
294
340
  </pre>
295
341
  <p><a class="source-toggle" href="#"
296
- onclick="toggleCode('M000211-source');return false;">[Source]</a></p>
297
- <div class="method-source-code" id="M000211-source">
342
+ onclick="toggleCode('M000233-source');return false;">[Source]</a></p>
343
+ <div class="method-source-code" id="M000233-source">
298
344
  <pre>
299
345
  /*
300
346
  * call-seq:
@@ -312,11 +358,11 @@ ruby_xml_attributes_first(VALUE self) {
312
358
  </div>
313
359
  </div>
314
360
 
315
- <div id="method-M000205" class="method-detail">
316
- <a name="M000205"></a>
361
+ <div id="method-M000227" class="method-detail">
362
+ <a name="M000227"></a>
317
363
 
318
364
  <div class="method-heading">
319
- <a href="#M000205" class="method-signature">
365
+ <a href="#M000227" class="method-signature">
320
366
  <span class="method-name">attributes.get_attribute("name") &rarr; XML::Attr<br />
321
367
  </span>
322
368
  </a>
@@ -333,8 +379,8 @@ name: The name of the attribute, not including a namespace.
333
379
  doc.root.attributes.get_attribute(&quot;foo&quot;)
334
380
  </pre>
335
381
  <p><a class="source-toggle" href="#"
336
- onclick="toggleCode('M000205-source');return false;">[Source]</a></p>
337
- <div class="method-source-code" id="M000205-source">
382
+ onclick="toggleCode('M000227-source');return false;">[Source]</a></p>
383
+ <div class="method-source-code" id="M000227-source">
338
384
  <pre>
339
385
  /*
340
386
  * call-seq:
@@ -354,11 +400,11 @@ ruby_xml_attributes_get_attribute(VALUE self, VALUE name) {
354
400
  </div>
355
401
  </div>
356
402
 
357
- <div id="method-M000206" class="method-detail">
358
- <a name="M000206"></a>
403
+ <div id="method-M000228" class="method-detail">
404
+ <a name="M000228"></a>
359
405
 
360
406
  <div class="method-heading">
361
- <a href="#M000206" class="method-signature">
407
+ <a href="#M000228" class="method-signature">
362
408
  <span class="method-name">attributes.get_attribute_ns("namespace", "name") &rarr; XML::Attr<br />
363
409
  </span>
364
410
  </a>
@@ -376,8 +422,8 @@ the attribute, not including a namespace.
376
422
  doc.root.attributes.get_attribute_ns('http://www.w3.org/1999/xlink', 'href')
377
423
  </pre>
378
424
  <p><a class="source-toggle" href="#"
379
- onclick="toggleCode('M000206-source');return false;">[Source]</a></p>
380
- <div class="method-source-code" id="M000206-source">
425
+ onclick="toggleCode('M000228-source');return false;">[Source]</a></p>
426
+ <div class="method-source-code" id="M000228-source">
381
427
  <pre>
382
428
  /*
383
429
  * call-seq:
@@ -398,11 +444,11 @@ ruby_xml_attributes_get_attribute_ns(VALUE self, VALUE namespace, VALUE name) {
398
444
  </div>
399
445
  </div>
400
446
 
401
- <div id="method-M000210" class="method-detail">
402
- <a name="M000210"></a>
447
+ <div id="method-M000232" class="method-detail">
448
+ <a name="M000232"></a>
403
449
 
404
450
  <div class="method-heading">
405
- <a href="#M000210" class="method-signature">
451
+ <a href="#M000232" class="method-signature">
406
452
  <span class="method-name">attributes.length &rarr; Integer<br />
407
453
  </span>
408
454
  </a>
@@ -416,8 +462,8 @@ Returns the number of attributes.
416
462
  doc.root.attributes.length
417
463
  </pre>
418
464
  <p><a class="source-toggle" href="#"
419
- onclick="toggleCode('M000210-source');return false;">[Source]</a></p>
420
- <div class="method-source-code" id="M000210-source">
465
+ onclick="toggleCode('M000232-source');return false;">[Source]</a></p>
466
+ <div class="method-source-code" id="M000232-source">
421
467
  <pre>
422
468
  /*
423
469
  * call-seq:
@@ -435,11 +481,11 @@ ruby_xml_attributes_length(VALUE self) {
435
481
  </div>
436
482
  </div>
437
483
 
438
- <div id="method-M000204" class="method-detail">
439
- <a name="M000204"></a>
484
+ <div id="method-M000226" class="method-detail">
485
+ <a name="M000226"></a>
440
486
 
441
487
  <div class="method-heading">
442
- <a href="#M000204" class="method-signature">
488
+ <a href="#M000226" class="method-signature">
443
489
  <span class="method-name">attributes.node &rarr; XML::Node<br />
444
490
  </span>
445
491
  </a>
@@ -453,8 +499,8 @@ Return the node that owns this attributes list.
453
499
  doc.root.attributes.node == doc.root
454
500
  </pre>
455
501
  <p><a class="source-toggle" href="#"
456
- onclick="toggleCode('M000204-source');return false;">[Source]</a></p>
457
- <div class="method-source-code" id="M000204-source">
502
+ onclick="toggleCode('M000226-source');return false;">[Source]</a></p>
503
+ <div class="method-source-code" id="M000226-source">
458
504
  <pre>
459
505
  /*
460
506
  * call-seq:
@@ -467,6 +513,32 @@ Return the node that owns this attributes list.
467
513
  VALUE
468
514
  ruby_xml_attributes_node_get(VALUE self) {
469
515
 
516
+ </pre>
517
+ </div>
518
+ </div>
519
+ </div>
520
+
521
+ <div id="method-M000234" class="method-detail">
522
+ <a name="M000234"></a>
523
+
524
+ <div class="method-heading">
525
+ <a href="#M000234" class="method-signature">
526
+ <span class="method-name">to_h</span><span class="method-args">()</span>
527
+ </a>
528
+ </div>
529
+
530
+ <div class="method-description">
531
+ <p><a class="source-toggle" href="#"
532
+ onclick="toggleCode('M000234-source');return false;">[Source]</a></p>
533
+ <div class="method-source-code" id="M000234-source">
534
+ <pre>
535
+ <span class="ruby-comment cmt"># File lib/libxml/attributes.rb, line 7</span>
536
+ 7: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">to_h</span>
537
+ 8: <span class="ruby-identifier">inject</span>({}) <span class="ruby-keyword kw">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">hash</span>, <span class="ruby-identifier">attr</span><span class="ruby-operator">|</span>
538
+ 9: <span class="ruby-identifier">hash</span>[<span class="ruby-identifier">attr</span>.<span class="ruby-identifier">name</span>] = <span class="ruby-identifier">attr</span>.<span class="ruby-identifier">value</span>
539
+ 10: <span class="ruby-identifier">hash</span>
540
+ 11: <span class="ruby-keyword kw">end</span>
541
+ 12: <span class="ruby-keyword kw">end</span>
470
542
  </pre>
471
543
  </div>
472
544
  </div>
@@ -5,10 +5,10 @@
5
5
 
6
6
  <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
7
7
  <head>
8
- <title>Class: XML::Document</title>
8
+ <title>Class: LibXML::XML::Document</title>
9
9
  <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
10
10
  <meta http-equiv="Content-Script-Type" content="text/javascript" />
11
- <link rel="stylesheet" href="../.././rdoc-style.css" type="text/css" media="screen" />
11
+ <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
12
12
  <script type="text/javascript">
13
13
  // <![CDATA[
14
14
 
@@ -50,17 +50,17 @@
50
50
  <table class="header-table">
51
51
  <tr class="top-aligned-row">
52
52
  <td><strong>Class</strong></td>
53
- <td class="class-name-in-header">XML::Document</td>
53
+ <td class="class-name-in-header">LibXML::XML::Document</td>
54
54
  </tr>
55
55
  <tr class="top-aligned-row">
56
56
  <td><strong>In:</strong></td>
57
57
  <td>
58
- <a href="../../files/ext/libxml/libxml_c.html">
58
+ <a href="../../../files/ext/libxml/libxml_c.html">
59
59
  ext/libxml/libxml.c
60
60
  </a>
61
61
  <br />
62
- <a href="../../files/lib/libxml_rb.html">
63
- lib/libxml.rb
62
+ <a href="../../../files/lib/libxml/document_rb.html">
63
+ lib/libxml/document.rb
64
64
  </a>
65
65
  <br />
66
66
  </td>
@@ -115,42 +115,42 @@ Writing:
115
115
  <h3 class="section-bar">Methods</h3>
116
116
 
117
117
  <div class="name-list">
118
- <a href="#M000308">child</a>&nbsp;&nbsp;
119
- <a href="#M000309">child?</a>&nbsp;&nbsp;
120
- <a href="#M000310">compression</a>&nbsp;&nbsp;
121
- <a href="#M000311">compression=</a>&nbsp;&nbsp;
122
- <a href="#M000312">compression?</a>&nbsp;&nbsp;
123
- <a href="#M000314">debug_dump</a>&nbsp;&nbsp;
124
- <a href="#M000315">debug_dump_head</a>&nbsp;&nbsp;
125
- <a href="#M000316">debug_format_dump</a>&nbsp;&nbsp;
126
- <a href="#M000313">dump</a>&nbsp;&nbsp;
127
- <a href="#M000341">each</a>&nbsp;&nbsp;
128
- <a href="#M000317">encoding</a>&nbsp;&nbsp;
129
- <a href="#M000318">encoding=</a>&nbsp;&nbsp;
130
- <a href="#M000306">file</a>&nbsp;&nbsp;
131
- <a href="#M000319">filename</a>&nbsp;&nbsp;
132
- <a href="#M000320">find</a>&nbsp;&nbsp;
133
- <a href="#M000321">format_dump</a>&nbsp;&nbsp;
134
- <a href="#M000322">last</a>&nbsp;&nbsp;
135
- <a href="#M000323">last?</a>&nbsp;&nbsp;
136
- <a href="#M000307">new</a>&nbsp;&nbsp;
137
- <a href="#M000324">next</a>&nbsp;&nbsp;
138
- <a href="#M000325">next?</a>&nbsp;&nbsp;
139
- <a href="#M000326">parent</a>&nbsp;&nbsp;
140
- <a href="#M000327">parent?</a>&nbsp;&nbsp;
141
- <a href="#M000328">prev</a>&nbsp;&nbsp;
142
- <a href="#M000329">prev?</a>&nbsp;&nbsp;
143
- <a href="#M000340">reader</a>&nbsp;&nbsp;
144
- <a href="#M000330">root</a>&nbsp;&nbsp;
145
- <a href="#M000331">root=</a>&nbsp;&nbsp;
146
- <a href="#M000332">save</a>&nbsp;&nbsp;
147
- <a href="#M000333">standalone?</a>&nbsp;&nbsp;
148
- <a href="#M000334">to_s</a>&nbsp;&nbsp;
149
- <a href="#M000335">url</a>&nbsp;&nbsp;
150
- <a href="#M000338">validate</a>&nbsp;&nbsp;
151
- <a href="#M000339">validate_schema</a>&nbsp;&nbsp;
152
- <a href="#M000336">version</a>&nbsp;&nbsp;
153
- <a href="#M000337">xinclude</a>&nbsp;&nbsp;
118
+ <a href="#M000323">child</a>&nbsp;&nbsp;
119
+ <a href="#M000324">child?</a>&nbsp;&nbsp;
120
+ <a href="#M000325">compression</a>&nbsp;&nbsp;
121
+ <a href="#M000326">compression=</a>&nbsp;&nbsp;
122
+ <a href="#M000327">compression?</a>&nbsp;&nbsp;
123
+ <a href="#M000329">debug_dump</a>&nbsp;&nbsp;
124
+ <a href="#M000330">debug_dump_head</a>&nbsp;&nbsp;
125
+ <a href="#M000331">debug_format_dump</a>&nbsp;&nbsp;
126
+ <a href="#M000328">dump</a>&nbsp;&nbsp;
127
+ <a href="#M000332">encoding</a>&nbsp;&nbsp;
128
+ <a href="#M000333">encoding=</a>&nbsp;&nbsp;
129
+ <a href="#M000321">file</a>&nbsp;&nbsp;
130
+ <a href="#M000334">filename</a>&nbsp;&nbsp;
131
+ <a href="#M000355">find</a>&nbsp;&nbsp;
132
+ <a href="#M000356">find_first</a>&nbsp;&nbsp;
133
+ <a href="#M000335">format_dump</a>&nbsp;&nbsp;
134
+ <a href="#M000336">last</a>&nbsp;&nbsp;
135
+ <a href="#M000337">last?</a>&nbsp;&nbsp;
136
+ <a href="#M000322">new</a>&nbsp;&nbsp;
137
+ <a href="#M000338">next</a>&nbsp;&nbsp;
138
+ <a href="#M000339">next?</a>&nbsp;&nbsp;
139
+ <a href="#M000340">parent</a>&nbsp;&nbsp;
140
+ <a href="#M000341">parent?</a>&nbsp;&nbsp;
141
+ <a href="#M000342">prev</a>&nbsp;&nbsp;
142
+ <a href="#M000343">prev?</a>&nbsp;&nbsp;
143
+ <a href="#M000354">reader</a>&nbsp;&nbsp;
144
+ <a href="#M000344">root</a>&nbsp;&nbsp;
145
+ <a href="#M000345">root=</a>&nbsp;&nbsp;
146
+ <a href="#M000346">save</a>&nbsp;&nbsp;
147
+ <a href="#M000347">standalone?</a>&nbsp;&nbsp;
148
+ <a href="#M000348">to_s</a>&nbsp;&nbsp;
149
+ <a href="#M000349">url</a>&nbsp;&nbsp;
150
+ <a href="#M000352">validate</a>&nbsp;&nbsp;
151
+ <a href="#M000353">validate_schema</a>&nbsp;&nbsp;
152
+ <a href="#M000350">version</a>&nbsp;&nbsp;
153
+ <a href="#M000351">xinclude</a>&nbsp;&nbsp;
154
154
  </div>
155
155
  </div>
156
156
 
@@ -158,13 +158,6 @@ Writing:
158
158
 
159
159
 
160
160
  <!-- if includes -->
161
- <div id="includes">
162
- <h3 class="section-bar">Included Modules</h3>
163
-
164
- <div id="includes-list">
165
- <span class="include-name">Enumerable</span>
166
- </div>
167
- </div>
168
161
 
169
162
  <div id="section">
170
163
 
@@ -179,11 +172,11 @@ Writing:
179
172
  <div id="methods">
180
173
  <h3 class="section-bar">Public Class methods</h3>
181
174
 
182
- <div id="method-M000306" class="method-detail">
183
- <a name="M000306"></a>
175
+ <div id="method-M000321" class="method-detail">
176
+ <a name="M000321"></a>
184
177
 
185
178
  <div class="method-heading">
186
- <a href="#M000306" class="method-signature">
179
+ <a href="#M000321" class="method-signature">
187
180
  <span class="method-name">XML::Document.file(filename) &rarr; document<br />
188
181
  </span>
189
182
  </a>
@@ -195,8 +188,8 @@ Create a new <a href="Document.html">XML::Document</a> by parsing the
195
188
  specified file.
196
189
  </p>
197
190
  <p><a class="source-toggle" href="#"
198
- onclick="toggleCode('M000306-source');return false;">[Source]</a></p>
199
- <div class="method-source-code" id="M000306-source">
191
+ onclick="toggleCode('M000321-source');return false;">[Source]</a></p>
192
+ <div class="method-source-code" id="M000321-source">
200
193
  <pre>
201
194
  /*
202
195
  * call-seq:
@@ -213,11 +206,11 @@ ruby_xml_document_new_file(VALUE class, VALUE filename) {
213
206
  </div>
214
207
  </div>
215
208
 
216
- <div id="method-M000307" class="method-detail">
217
- <a name="M000307"></a>
209
+ <div id="method-M000322" class="method-detail">
210
+ <a name="M000322"></a>
218
211
 
219
212
  <div class="method-heading">
220
- <a href="#M000307" class="method-signature">
213
+ <a href="#M000322" class="method-signature">
221
214
  <span class="method-name">XML::Document.new(xml_version = 1.0) &rarr; document<br />
222
215
  </span>
223
216
  </a>
@@ -229,8 +222,8 @@ Create a new <a href="Document.html">XML::Document</a>, optionally
229
222
  specifying the <a href="../XML.html">XML</a> version.
230
223
  </p>
231
224
  <p><a class="source-toggle" href="#"
232
- onclick="toggleCode('M000307-source');return false;">[Source]</a></p>
233
- <div class="method-source-code" id="M000307-source">
225
+ onclick="toggleCode('M000322-source');return false;">[Source]</a></p>
226
+ <div class="method-source-code" id="M000322-source">
234
227
  <pre>
235
228
  /*
236
229
  * call-seq:
@@ -249,11 +242,11 @@ ruby_xml_document_new(int argc, VALUE *argv, VALUE class) {
249
242
 
250
243
  <h3 class="section-bar">Public Instance methods</h3>
251
244
 
252
- <div id="method-M000308" class="method-detail">
253
- <a name="M000308"></a>
245
+ <div id="method-M000323" class="method-detail">
246
+ <a name="M000323"></a>
254
247
 
255
248
  <div class="method-heading">
256
- <a href="#M000308" class="method-signature">
249
+ <a href="#M000323" class="method-signature">
257
250
  <span class="method-name">document.child &rarr; node<br />
258
251
  </span>
259
252
  </a>
@@ -264,8 +257,8 @@ ruby_xml_document_new(int argc, VALUE *argv, VALUE class) {
264
257
  Get this document&#8217;s child node.
265
258
  </p>
266
259
  <p><a class="source-toggle" href="#"
267
- onclick="toggleCode('M000308-source');return false;">[Source]</a></p>
268
- <div class="method-source-code" id="M000308-source">
260
+ onclick="toggleCode('M000323-source');return false;">[Source]</a></p>
261
+ <div class="method-source-code" id="M000323-source">
269
262
  <pre>
270
263
  /*
271
264
  * call-seq:
@@ -281,11 +274,11 @@ ruby_xml_document_child_get(VALUE self) {
281
274
  </div>
282
275
  </div>
283
276
 
284
- <div id="method-M000309" class="method-detail">
285
- <a name="M000309"></a>
277
+ <div id="method-M000324" class="method-detail">
278
+ <a name="M000324"></a>
286
279
 
287
280
  <div class="method-heading">
288
- <a href="#M000309" class="method-signature">
281
+ <a href="#M000324" class="method-signature">
289
282
  <span class="method-name">document.child? &rarr; (true|false)<br />
290
283
  </span>
291
284
  </a>
@@ -296,8 +289,8 @@ ruby_xml_document_child_get(VALUE self) {
296
289
  Determine whether this document has a child node.
297
290
  </p>
298
291
  <p><a class="source-toggle" href="#"
299
- onclick="toggleCode('M000309-source');return false;">[Source]</a></p>
300
- <div class="method-source-code" id="M000309-source">
292
+ onclick="toggleCode('M000324-source');return false;">[Source]</a></p>
293
+ <div class="method-source-code" id="M000324-source">
301
294
  <pre>
302
295
  /*
303
296
  * call-seq:
@@ -313,11 +306,11 @@ ruby_xml_document_child_q(VALUE self) {
313
306
  </div>
314
307
  </div>
315
308
 
316
- <div id="method-M000310" class="method-detail">
317
- <a name="M000310"></a>
309
+ <div id="method-M000325" class="method-detail">
310
+ <a name="M000325"></a>
318
311
 
319
312
  <div class="method-heading">
320
- <a href="#M000310" class="method-signature">
313
+ <a href="#M000325" class="method-signature">
321
314
  <span class="method-name">document.compression &rarr; num<br />
322
315
  </span>
323
316
  </a>
@@ -328,8 +321,8 @@ ruby_xml_document_child_q(VALUE self) {
328
321
  Obtain this document&#8217;s compression mode identifier.
329
322
  </p>
330
323
  <p><a class="source-toggle" href="#"
331
- onclick="toggleCode('M000310-source');return false;">[Source]</a></p>
332
- <div class="method-source-code" id="M000310-source">
324
+ onclick="toggleCode('M000325-source');return false;">[Source]</a></p>
325
+ <div class="method-source-code" id="M000325-source">
333
326
  <pre>
334
327
  /*
335
328
  * call-seq:
@@ -345,11 +338,11 @@ ruby_xml_document_compression_get(VALUE self) {
345
338
  </div>
346
339
  </div>
347
340
 
348
- <div id="method-M000311" class="method-detail">
349
- <a name="M000311"></a>
341
+ <div id="method-M000326" class="method-detail">
342
+ <a name="M000326"></a>
350
343
 
351
344
  <div class="method-heading">
352
- <a href="#M000311" class="method-signature">
345
+ <a href="#M000326" class="method-signature">
353
346
  <span class="method-name">document.compression = num<br />
354
347
  </span>
355
348
  </a>
@@ -360,8 +353,8 @@ ruby_xml_document_compression_get(VALUE self) {
360
353
  Set this document&#8217;s compression mode.
361
354
  </p>
362
355
  <p><a class="source-toggle" href="#"
363
- onclick="toggleCode('M000311-source');return false;">[Source]</a></p>
364
- <div class="method-source-code" id="M000311-source">
356
+ onclick="toggleCode('M000326-source');return false;">[Source]</a></p>
357
+ <div class="method-source-code" id="M000326-source">
365
358
  <pre>
366
359
  /*
367
360
  * call-seq:
@@ -377,11 +370,11 @@ ruby_xml_document_compression_set(VALUE self, VALUE num) {
377
370
  </div>
378
371
  </div>
379
372
 
380
- <div id="method-M000312" class="method-detail">
381
- <a name="M000312"></a>
373
+ <div id="method-M000327" class="method-detail">
374
+ <a name="M000327"></a>
382
375
 
383
376
  <div class="method-heading">
384
- <a href="#M000312" class="method-signature">
377
+ <a href="#M000327" class="method-signature">
385
378
  <span class="method-name">document.compression? &rarr; (true|false)<br />
386
379
  </span>
387
380
  </a>
@@ -392,8 +385,8 @@ ruby_xml_document_compression_set(VALUE self, VALUE num) {
392
385
  Determine whether this document is compressed.
393
386
  </p>
394
387
  <p><a class="source-toggle" href="#"
395
- onclick="toggleCode('M000312-source');return false;">[Source]</a></p>
396
- <div class="method-source-code" id="M000312-source">
388
+ onclick="toggleCode('M000327-source');return false;">[Source]</a></p>
389
+ <div class="method-source-code" id="M000327-source">
397
390
  <pre>
398
391
  /*
399
392
  * call-seq:
@@ -409,11 +402,11 @@ ruby_xml_document_compression_q(VALUE self) {
409
402
  </div>
410
403
  </div>
411
404
 
412
- <div id="method-M000314" class="method-detail">
413
- <a name="M000314"></a>
405
+ <div id="method-M000329" class="method-detail">
406
+ <a name="M000329"></a>
414
407
 
415
408
  <div class="method-heading">
416
- <a href="#M000314" class="method-signature">
409
+ <a href="#M000329" class="method-signature">
417
410
  <span class="method-name">document.debug_dump([stream]) &rarr; true<br />
418
411
  </span>
419
412
  </a>
@@ -424,8 +417,8 @@ ruby_xml_document_compression_q(VALUE self) {
424
417
  Debug version of dump.
425
418
  </p>
426
419
  <p><a class="source-toggle" href="#"
427
- onclick="toggleCode('M000314-source');return false;">[Source]</a></p>
428
- <div class="method-source-code" id="M000314-source">
420
+ onclick="toggleCode('M000329-source');return false;">[Source]</a></p>
421
+ <div class="method-source-code" id="M000329-source">
429
422
  <pre>
430
423
  /*
431
424
  * call-seq:
@@ -441,11 +434,11 @@ ruby_xml_document_debug_dump(int argc, VALUE *argv, VALUE self) {
441
434
  </div>
442
435
  </div>
443
436
 
444
- <div id="method-M000315" class="method-detail">
445
- <a name="M000315"></a>
437
+ <div id="method-M000330" class="method-detail">
438
+ <a name="M000330"></a>
446
439
 
447
440
  <div class="method-heading">
448
- <a href="#M000315" class="method-signature">
441
+ <a href="#M000330" class="method-signature">
449
442
  <span class="method-name">document.debug_dump_head([stream]) &rarr; true<br />
450
443
  </span>
451
444
  </a>
@@ -457,8 +450,8 @@ Debug-dump this document&#8217;s header to the specified IO stream. If no
457
450
  stream is specified, stdout is used.
458
451
  </p>
459
452
  <p><a class="source-toggle" href="#"
460
- onclick="toggleCode('M000315-source');return false;">[Source]</a></p>
461
- <div class="method-source-code" id="M000315-source">
453
+ onclick="toggleCode('M000330-source');return false;">[Source]</a></p>
454
+ <div class="method-source-code" id="M000330-source">
462
455
  <pre>
463
456
  /*
464
457
  * call-seq:
@@ -475,11 +468,11 @@ ruby_xml_document_debug_dump_head(int argc, VALUE *argv, VALUE self) {
475
468
  </div>
476
469
  </div>
477
470
 
478
- <div id="method-M000316" class="method-detail">
479
- <a name="M000316"></a>
471
+ <div id="method-M000331" class="method-detail">
472
+ <a name="M000331"></a>
480
473
 
481
474
  <div class="method-heading">
482
- <a href="#M000316" class="method-signature">
475
+ <a href="#M000331" class="method-signature">
483
476
  <span class="method-name">document.debug_format_dump([stream]) &rarr; true<br />
484
477
  </span>
485
478
  </a>
@@ -488,11 +481,11 @@ ruby_xml_document_debug_dump_head(int argc, VALUE *argv, VALUE self) {
488
481
  <div class="method-description">
489
482
  <p>
490
483
  <b>Deprecated</b> in favour of <a
491
- href="Document.html#M000321">format_dump</a>.
484
+ href="Document.html#M000335">format_dump</a>.
492
485
  </p>
493
486
  <p><a class="source-toggle" href="#"
494
- onclick="toggleCode('M000316-source');return false;">[Source]</a></p>
495
- <div class="method-source-code" id="M000316-source">
487
+ onclick="toggleCode('M000331-source');return false;">[Source]</a></p>
488
+ <div class="method-source-code" id="M000331-source">
496
489
  <pre>
497
490
  /*
498
491
  * call-seq:
@@ -508,11 +501,11 @@ ruby_xml_document_debug_format_dump(int argc, VALUE *argv, VALUE self) {
508
501
  </div>
509
502
  </div>
510
503
 
511
- <div id="method-M000313" class="method-detail">
512
- <a name="M000313"></a>
504
+ <div id="method-M000328" class="method-detail">
505
+ <a name="M000328"></a>
513
506
 
514
507
  <div class="method-heading">
515
- <a href="#M000313" class="method-signature">
508
+ <a href="#M000328" class="method-signature">
516
509
  <span class="method-name">document.dump([stream]) &rarr; true<br />
517
510
  </span>
518
511
  </a>
@@ -524,8 +517,8 @@ Dump this document&#8217;s <a href="../XML.html">XML</a> to the specified
524
517
  IO stream. If no stream is specified, stdout is used.
525
518
  </p>
526
519
  <p><a class="source-toggle" href="#"
527
- onclick="toggleCode('M000313-source');return false;">[Source]</a></p>
528
- <div class="method-source-code" id="M000313-source">
520
+ onclick="toggleCode('M000328-source');return false;">[Source]</a></p>
521
+ <div class="method-source-code" id="M000328-source">
529
522
  <pre>
530
523
  /*
531
524
  * call-seq:
@@ -542,37 +535,11 @@ ruby_xml_document_dump(int argc, VALUE *argv, VALUE self) {
542
535
  </div>
543
536
  </div>
544
537
 
545
- <div id="method-M000341" class="method-detail">
546
- <a name="M000341"></a>
547
-
548
- <div class="method-heading">
549
- <a href="#M000341" class="method-signature">
550
- <span class="method-name">each</span><span class="method-args">(&amp;blk)</span>
551
- </a>
552
- </div>
553
-
554
- <div class="method-description">
555
- <p>
556
- maybe, maybe not&#8230;
557
- </p>
558
- <p><a class="source-toggle" href="#"
559
- onclick="toggleCode('M000341-source');return false;">[Source]</a></p>
560
- <div class="method-source-code" id="M000341-source">
561
- <pre>
562
- <span class="ruby-comment cmt"># File lib/libxml.rb, line 30</span>
563
- 30: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">each</span>(<span class="ruby-operator">&amp;</span><span class="ruby-identifier">blk</span>)
564
- 31: <span class="ruby-identifier">find</span>(<span class="ruby-value str">'//*'</span>).<span class="ruby-identifier">each</span>(<span class="ruby-operator">&amp;</span><span class="ruby-identifier">blk</span>)
565
- 32: <span class="ruby-keyword kw">end</span>
566
- </pre>
567
- </div>
568
- </div>
569
- </div>
570
-
571
- <div id="method-M000317" class="method-detail">
572
- <a name="M000317"></a>
538
+ <div id="method-M000332" class="method-detail">
539
+ <a name="M000332"></a>
573
540
 
574
541
  <div class="method-heading">
575
- <a href="#M000317" class="method-signature">
542
+ <a href="#M000332" class="method-signature">
576
543
  <span class="method-name">document.encoding &rarr; "encoding"<br />
577
544
  </span>
578
545
  </a>
@@ -583,8 +550,8 @@ maybe, maybe not&#8230;
583
550
  Obtain the encoding specified by this document.
584
551
  </p>
585
552
  <p><a class="source-toggle" href="#"
586
- onclick="toggleCode('M000317-source');return false;">[Source]</a></p>
587
- <div class="method-source-code" id="M000317-source">
553
+ onclick="toggleCode('M000332-source');return false;">[Source]</a></p>
554
+ <div class="method-source-code" id="M000332-source">
588
555
  <pre>
589
556
  /*
590
557
  * call-seq:
@@ -600,11 +567,11 @@ ruby_xml_document_encoding_get(VALUE self) {
600
567
  </div>
601
568
  </div>
602
569
 
603
- <div id="method-M000318" class="method-detail">
604
- <a name="M000318"></a>
570
+ <div id="method-M000333" class="method-detail">
571
+ <a name="M000333"></a>
605
572
 
606
573
  <div class="method-heading">
607
- <a href="#M000318" class="method-signature">
574
+ <a href="#M000333" class="method-signature">
608
575
  <span class="method-name">document.encoding = "encoding"<br />
609
576
  </span>
610
577
  </a>
@@ -615,8 +582,8 @@ ruby_xml_document_encoding_get(VALUE self) {
615
582
  Set the encoding for this document.
616
583
  </p>
617
584
  <p><a class="source-toggle" href="#"
618
- onclick="toggleCode('M000318-source');return false;">[Source]</a></p>
619
- <div class="method-source-code" id="M000318-source">
585
+ onclick="toggleCode('M000333-source');return false;">[Source]</a></p>
586
+ <div class="method-source-code" id="M000333-source">
620
587
  <pre>
621
588
  /*
622
589
  * call-seq:
@@ -632,11 +599,11 @@ ruby_xml_document_encoding_set(VALUE self, VALUE encoding) {
632
599
  </div>
633
600
  </div>
634
601
 
635
- <div id="method-M000319" class="method-detail">
636
- <a name="M000319"></a>
602
+ <div id="method-M000334" class="method-detail">
603
+ <a name="M000334"></a>
637
604
 
638
605
  <div class="method-heading">
639
- <a href="#M000319" class="method-signature">
606
+ <a href="#M000334" class="method-signature">
640
607
  <span class="method-name">document.filename &rarr; "filename"<br />
641
608
  </span>
642
609
  </a>
@@ -647,8 +614,8 @@ ruby_xml_document_encoding_set(VALUE self, VALUE encoding) {
647
614
  Obtain the filename this document was read from.
648
615
  </p>
649
616
  <p><a class="source-toggle" href="#"
650
- onclick="toggleCode('M000319-source');return false;">[Source]</a></p>
651
- <div class="method-source-code" id="M000319-source">
617
+ onclick="toggleCode('M000334-source');return false;">[Source]</a></p>
618
+ <div class="method-source-code" id="M000334-source">
652
619
  <pre>
653
620
  /*
654
621
  * call-seq:
@@ -664,23 +631,40 @@ ruby_xml_document_filename_get(VALUE self) {
664
631
  </div>
665
632
  </div>
666
633
 
667
- <div id="method-M000320" class="method-detail">
668
- <a name="M000320"></a>
634
+ <div id="method-M000355" class="method-detail">
635
+ <a name="M000355"></a>
669
636
 
670
637
  <div class="method-heading">
671
- <a href="#M000320" class="method-signature">
672
- <span class="method-name">document.find(xpath_expr, [namespace]) &rarr; XML::Node::Set<br />
673
- </span>
638
+ <a href="#M000355" class="method-signature">
639
+ <span class="method-name">find</span><span class="method-args">(xpath, nslist = nil)</span>
674
640
  </a>
675
641
  </div>
676
642
 
677
643
  <div class="method-description">
678
644
  <p>
679
- Find nodes matching the specified xpath expression, optionally using the
680
- specified namespace. Returns an <a href="Node/Set.html">XML::Node::Set</a>.
681
- For more information about working with namespaces, please refer to the <a
682
- href="XPath.html">XML::XPath</a> documentation.
645
+ Return the nodes matching the specified xpath expression, optionally using
646
+ the specified namespace. For more information about working with
647
+ namespaces, please refer to the <a href="XPath.html">XML::XPath</a>
648
+ documentation.
649
+ </p>
650
+ <p>
651
+ Parameters:
683
652
  </p>
653
+ <ul>
654
+ <li>xpath - The xpath expression as a string
655
+
656
+ </li>
657
+ <li>namespaces - An optional list of namespaces (see <a
658
+ href="XPath.html">XML::XPath</a> for information).
659
+
660
+ </li>
661
+ <li>Returns - <a href="XPath/Object.html">XML::XPath::Object</a>
662
+
663
+ </li>
664
+ </ul>
665
+ <pre>
666
+ document.find('/foo', 'xlink:http://www.w3.org/1999/xlink')
667
+ </pre>
684
668
  <p>
685
669
  IMPORTANT - The returned <a href="Node/Set.html">XML::Node::Set</a> must be
686
670
  freed before its associated document. In a running Ruby program this will
@@ -689,10 +673,8 @@ However, if the program exits, Ruby does not guarantee the order in which
689
673
  objects are freed (see <a
690
674
  href="http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-core/17700">blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-core/17700</a>).
691
675
  As a result, the associated document may be freed before the node list,
692
- which will cause a segmentation fault.
693
- </p>
694
- <p>
695
- To avoid this, use the following (non-ruby like) coding style:
676
+ which will cause a segmentation fault. To avoid this, use the following
677
+ (non-ruby like) coding style:
696
678
  </p>
697
679
  <pre>
698
680
  nodes = doc.find('/header')
@@ -704,50 +686,56 @@ To avoid this, use the following (non-ruby like) coding style:
704
686
  GC.start
705
687
  </pre>
706
688
  <p><a class="source-toggle" href="#"
707
- onclick="toggleCode('M000320-source');return false;">[Source]</a></p>
708
- <div class="method-source-code" id="M000320-source">
689
+ onclick="toggleCode('M000355-source');return false;">[Source]</a></p>
690
+ <div class="method-source-code" id="M000355-source">
709
691
  <pre>
710
- /*
711
- * call-seq:
712
- * document.find(xpath_expr, [namespace]) -&gt; XML::Node::Set
713
- *
714
- * Find nodes matching the specified xpath expression, optionally
715
- * using the specified namespace. Returns an XML::Node::Set. For
716
- * more information about working with namespaces, please refer
717
- * to the XML::XPath documentation.
718
- *
719
- * IMPORTANT - The returned XML::Node::Set must be freed before
720
- * its associated document. In a running Ruby program this will
721
- * happen automatically via Ruby's mark and sweep garbage collector.
722
- * However, if the program exits, Ruby does not guarantee the order
723
- * in which objects are freed
724
- * (see http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-core/17700).
725
- * As a result, the associated document may be freed before the node
726
- * list, which will cause a segmentation fault.
727
- *
728
- * To avoid this, use the following (non-ruby like) coding style:
729
- *
730
- * nodes = doc.find('/header')
731
- * nodes.each do |node|
732
- * ... do stuff ...
733
- * end
734
- *
735
- * nodes = nil
736
- * GC.start
737
- */
738
- VALUE
739
- ruby_xml_document_find(int argc, VALUE *argv, VALUE self) {
692
+ <span class="ruby-comment cmt"># File lib/libxml/document.rb, line 37</span>
693
+ 37: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">find</span>(<span class="ruby-identifier">xpath</span>, <span class="ruby-identifier">nslist</span> = <span class="ruby-keyword kw">nil</span>)
694
+ 38: <span class="ruby-identifier">context</span> = <span class="ruby-constant">XPath</span><span class="ruby-operator">::</span><span class="ruby-constant">Context</span>.<span class="ruby-identifier">new</span>(<span class="ruby-keyword kw">self</span>)
695
+ 39: <span class="ruby-identifier">context</span>.<span class="ruby-identifier">node</span> = <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">root</span>
696
+ 40: <span class="ruby-identifier">context</span>.<span class="ruby-identifier">register_namespaces_from_node</span>(<span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">root</span>)
697
+ 41: <span class="ruby-identifier">context</span>.<span class="ruby-identifier">register_namespaces</span>(<span class="ruby-identifier">nslist</span>) <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">nslist</span>
698
+ 42:
699
+ 43: <span class="ruby-identifier">context</span>.<span class="ruby-identifier">find</span>(<span class="ruby-identifier">xpath</span>)
700
+ 44: <span class="ruby-keyword kw">end</span>
701
+ </pre>
702
+ </div>
703
+ </div>
704
+ </div>
705
+
706
+ <div id="method-M000356" class="method-detail">
707
+ <a name="M000356"></a>
740
708
 
709
+ <div class="method-heading">
710
+ <a href="#M000356" class="method-signature">
711
+ <span class="method-name">find_first</span><span class="method-args">(xpath, nslist = nil)</span>
712
+ </a>
713
+ </div>
714
+
715
+ <div class="method-description">
716
+ <p>
717
+ Return the first node matching the specified xpath expression. For more
718
+ information, please refer to the documentation for <a
719
+ href="Document.html#M000355">XML::Document#find</a>.
720
+ </p>
721
+ <p><a class="source-toggle" href="#"
722
+ onclick="toggleCode('M000356-source');return false;">[Source]</a></p>
723
+ <div class="method-source-code" id="M000356-source">
724
+ <pre>
725
+ <span class="ruby-comment cmt"># File lib/libxml/document.rb, line 49</span>
726
+ 49: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">find_first</span>(<span class="ruby-identifier">xpath</span>, <span class="ruby-identifier">nslist</span> = <span class="ruby-keyword kw">nil</span>)
727
+ 50: <span class="ruby-identifier">find</span>(<span class="ruby-identifier">xpath</span>, <span class="ruby-identifier">nslist</span>).<span class="ruby-identifier">first</span>
728
+ 51: <span class="ruby-keyword kw">end</span>
741
729
  </pre>
742
730
  </div>
743
731
  </div>
744
732
  </div>
745
733
 
746
- <div id="method-M000321" class="method-detail">
747
- <a name="M000321"></a>
734
+ <div id="method-M000335" class="method-detail">
735
+ <a name="M000335"></a>
748
736
 
749
737
  <div class="method-heading">
750
- <a href="#M000321" class="method-signature">
738
+ <a href="#M000335" class="method-signature">
751
739
  <span class="method-name">document.format_dump([stream], [spacing]) &rarr; true<br />
752
740
  </span>
753
741
  </a>
@@ -760,8 +748,8 @@ specified IO stream. If no stream is specified, stdout is used. If spacing
760
748
  is specified, it must be a boolean that determines whether spacing is used.
761
749
  </p>
762
750
  <p><a class="source-toggle" href="#"
763
- onclick="toggleCode('M000321-source');return false;">[Source]</a></p>
764
- <div class="method-source-code" id="M000321-source">
751
+ onclick="toggleCode('M000335-source');return false;">[Source]</a></p>
752
+ <div class="method-source-code" id="M000335-source">
765
753
  <pre>
766
754
  /*
767
755
  * call-seq:
@@ -780,11 +768,11 @@ ruby_xml_document_format_dump(int argc, VALUE *argv, VALUE self) {
780
768
  </div>
781
769
  </div>
782
770
 
783
- <div id="method-M000322" class="method-detail">
784
- <a name="M000322"></a>
771
+ <div id="method-M000336" class="method-detail">
772
+ <a name="M000336"></a>
785
773
 
786
774
  <div class="method-heading">
787
- <a href="#M000322" class="method-signature">
775
+ <a href="#M000336" class="method-signature">
788
776
  <span class="method-name">document.last &rarr; node<br />
789
777
  </span>
790
778
  </a>
@@ -795,8 +783,8 @@ ruby_xml_document_format_dump(int argc, VALUE *argv, VALUE self) {
795
783
  Obtain the last node.
796
784
  </p>
797
785
  <p><a class="source-toggle" href="#"
798
- onclick="toggleCode('M000322-source');return false;">[Source]</a></p>
799
- <div class="method-source-code" id="M000322-source">
786
+ onclick="toggleCode('M000336-source');return false;">[Source]</a></p>
787
+ <div class="method-source-code" id="M000336-source">
800
788
  <pre>
801
789
  /*
802
790
  * call-seq:
@@ -812,11 +800,11 @@ ruby_xml_document_last_get(VALUE self) {
812
800
  </div>
813
801
  </div>
814
802
 
815
- <div id="method-M000323" class="method-detail">
816
- <a name="M000323"></a>
803
+ <div id="method-M000337" class="method-detail">
804
+ <a name="M000337"></a>
817
805
 
818
806
  <div class="method-heading">
819
- <a href="#M000323" class="method-signature">
807
+ <a href="#M000337" class="method-signature">
820
808
  <span class="method-name">document.last? &rarr; (true|false)<br />
821
809
  </span>
822
810
  </a>
@@ -827,8 +815,8 @@ ruby_xml_document_last_get(VALUE self) {
827
815
  Determine whether there is a last node.
828
816
  </p>
829
817
  <p><a class="source-toggle" href="#"
830
- onclick="toggleCode('M000323-source');return false;">[Source]</a></p>
831
- <div class="method-source-code" id="M000323-source">
818
+ onclick="toggleCode('M000337-source');return false;">[Source]</a></p>
819
+ <div class="method-source-code" id="M000337-source">
832
820
  <pre>
833
821
  /*
834
822
  * call-seq:
@@ -844,11 +832,11 @@ ruby_xml_document_last_q(VALUE self) {
844
832
  </div>
845
833
  </div>
846
834
 
847
- <div id="method-M000324" class="method-detail">
848
- <a name="M000324"></a>
835
+ <div id="method-M000338" class="method-detail">
836
+ <a name="M000338"></a>
849
837
 
850
838
  <div class="method-heading">
851
- <a href="#M000324" class="method-signature">
839
+ <a href="#M000338" class="method-signature">
852
840
  <span class="method-name">document.next &rarr; node<br />
853
841
  </span>
854
842
  </a>
@@ -859,8 +847,8 @@ ruby_xml_document_last_q(VALUE self) {
859
847
  Obtain the next node.
860
848
  </p>
861
849
  <p><a class="source-toggle" href="#"
862
- onclick="toggleCode('M000324-source');return false;">[Source]</a></p>
863
- <div class="method-source-code" id="M000324-source">
850
+ onclick="toggleCode('M000338-source');return false;">[Source]</a></p>
851
+ <div class="method-source-code" id="M000338-source">
864
852
  <pre>
865
853
  /*
866
854
  * call-seq:
@@ -876,11 +864,11 @@ ruby_xml_document_next_get(VALUE self) {
876
864
  </div>
877
865
  </div>
878
866
 
879
- <div id="method-M000325" class="method-detail">
880
- <a name="M000325"></a>
867
+ <div id="method-M000339" class="method-detail">
868
+ <a name="M000339"></a>
881
869
 
882
870
  <div class="method-heading">
883
- <a href="#M000325" class="method-signature">
871
+ <a href="#M000339" class="method-signature">
884
872
  <span class="method-name">document.next? &rarr; (true|false)<br />
885
873
  </span>
886
874
  </a>
@@ -891,8 +879,8 @@ ruby_xml_document_next_get(VALUE self) {
891
879
  Determine whether there is a next node.
892
880
  </p>
893
881
  <p><a class="source-toggle" href="#"
894
- onclick="toggleCode('M000325-source');return false;">[Source]</a></p>
895
- <div class="method-source-code" id="M000325-source">
882
+ onclick="toggleCode('M000339-source');return false;">[Source]</a></p>
883
+ <div class="method-source-code" id="M000339-source">
896
884
  <pre>
897
885
  /*
898
886
  * call-seq:
@@ -908,11 +896,11 @@ ruby_xml_document_next_q(VALUE self) {
908
896
  </div>
909
897
  </div>
910
898
 
911
- <div id="method-M000326" class="method-detail">
912
- <a name="M000326"></a>
899
+ <div id="method-M000340" class="method-detail">
900
+ <a name="M000340"></a>
913
901
 
914
902
  <div class="method-heading">
915
- <a href="#M000326" class="method-signature">
903
+ <a href="#M000340" class="method-signature">
916
904
  <span class="method-name">document.parent &rarr; node<br />
917
905
  </span>
918
906
  </a>
@@ -923,8 +911,8 @@ ruby_xml_document_next_q(VALUE self) {
923
911
  Obtain the parent node.
924
912
  </p>
925
913
  <p><a class="source-toggle" href="#"
926
- onclick="toggleCode('M000326-source');return false;">[Source]</a></p>
927
- <div class="method-source-code" id="M000326-source">
914
+ onclick="toggleCode('M000340-source');return false;">[Source]</a></p>
915
+ <div class="method-source-code" id="M000340-source">
928
916
  <pre>
929
917
  /*
930
918
  * call-seq:
@@ -940,11 +928,11 @@ ruby_xml_document_parent_get(VALUE self) {
940
928
  </div>
941
929
  </div>
942
930
 
943
- <div id="method-M000327" class="method-detail">
944
- <a name="M000327"></a>
931
+ <div id="method-M000341" class="method-detail">
932
+ <a name="M000341"></a>
945
933
 
946
934
  <div class="method-heading">
947
- <a href="#M000327" class="method-signature">
935
+ <a href="#M000341" class="method-signature">
948
936
  <span class="method-name">document.parent? &rarr; (true|false)<br />
949
937
  </span>
950
938
  </a>
@@ -955,8 +943,8 @@ ruby_xml_document_parent_get(VALUE self) {
955
943
  Determine whether there is a parent node.
956
944
  </p>
957
945
  <p><a class="source-toggle" href="#"
958
- onclick="toggleCode('M000327-source');return false;">[Source]</a></p>
959
- <div class="method-source-code" id="M000327-source">
946
+ onclick="toggleCode('M000341-source');return false;">[Source]</a></p>
947
+ <div class="method-source-code" id="M000341-source">
960
948
  <pre>
961
949
  /*
962
950
  * call-seq:
@@ -972,11 +960,11 @@ ruby_xml_document_parent_q(VALUE self) {
972
960
  </div>
973
961
  </div>
974
962
 
975
- <div id="method-M000328" class="method-detail">
976
- <a name="M000328"></a>
963
+ <div id="method-M000342" class="method-detail">
964
+ <a name="M000342"></a>
977
965
 
978
966
  <div class="method-heading">
979
- <a href="#M000328" class="method-signature">
967
+ <a href="#M000342" class="method-signature">
980
968
  <span class="method-name">document.prev &rarr; node<br />
981
969
  </span>
982
970
  </a>
@@ -987,8 +975,8 @@ ruby_xml_document_parent_q(VALUE self) {
987
975
  Obtain the previous node.
988
976
  </p>
989
977
  <p><a class="source-toggle" href="#"
990
- onclick="toggleCode('M000328-source');return false;">[Source]</a></p>
991
- <div class="method-source-code" id="M000328-source">
978
+ onclick="toggleCode('M000342-source');return false;">[Source]</a></p>
979
+ <div class="method-source-code" id="M000342-source">
992
980
  <pre>
993
981
  /*
994
982
  * call-seq:
@@ -1004,11 +992,11 @@ ruby_xml_document_prev_get(VALUE self) {
1004
992
  </div>
1005
993
  </div>
1006
994
 
1007
- <div id="method-M000329" class="method-detail">
1008
- <a name="M000329"></a>
995
+ <div id="method-M000343" class="method-detail">
996
+ <a name="M000343"></a>
1009
997
 
1010
998
  <div class="method-heading">
1011
- <a href="#M000329" class="method-signature">
999
+ <a href="#M000343" class="method-signature">
1012
1000
  <span class="method-name">document.prev? &rarr; (true|false)<br />
1013
1001
  </span>
1014
1002
  </a>
@@ -1019,8 +1007,8 @@ ruby_xml_document_prev_get(VALUE self) {
1019
1007
  Determine whether there is a previous node.
1020
1008
  </p>
1021
1009
  <p><a class="source-toggle" href="#"
1022
- onclick="toggleCode('M000329-source');return false;">[Source]</a></p>
1023
- <div class="method-source-code" id="M000329-source">
1010
+ onclick="toggleCode('M000343-source');return false;">[Source]</a></p>
1011
+ <div class="method-source-code" id="M000343-source">
1024
1012
  <pre>
1025
1013
  /*
1026
1014
  * call-seq:
@@ -1036,11 +1024,11 @@ ruby_xml_document_prev_q(VALUE self) {
1036
1024
  </div>
1037
1025
  </div>
1038
1026
 
1039
- <div id="method-M000340" class="method-detail">
1040
- <a name="M000340"></a>
1027
+ <div id="method-M000354" class="method-detail">
1028
+ <a name="M000354"></a>
1041
1029
 
1042
1030
  <div class="method-heading">
1043
- <a href="#M000340" class="method-signature">
1031
+ <a href="#M000354" class="method-signature">
1044
1032
  <span class="method-name">document.reader &rarr; reader<br />
1045
1033
  </span>
1046
1034
  </a>
@@ -1049,11 +1037,11 @@ ruby_xml_document_prev_q(VALUE self) {
1049
1037
  <div class="method-description">
1050
1038
  <p>
1051
1039
  Create a <a href="Reader.html">XML::Reader</a> from the document. This is a
1052
- shortcut to <a href="Reader.html#M000250">XML::Reader.walker</a>().
1040
+ shortcut to <a href="Reader.html#M000265">XML::Reader.walker</a>().
1053
1041
  </p>
1054
1042
  <p><a class="source-toggle" href="#"
1055
- onclick="toggleCode('M000340-source');return false;">[Source]</a></p>
1056
- <div class="method-source-code" id="M000340-source">
1043
+ onclick="toggleCode('M000354-source');return false;">[Source]</a></p>
1044
+ <div class="method-source-code" id="M000354-source">
1057
1045
  <pre>
1058
1046
  /*
1059
1047
  * call-seq:
@@ -1072,11 +1060,11 @@ ruby_xml_document_reader(VALUE self)
1072
1060
  </div>
1073
1061
  </div>
1074
1062
 
1075
- <div id="method-M000330" class="method-detail">
1076
- <a name="M000330"></a>
1063
+ <div id="method-M000344" class="method-detail">
1064
+ <a name="M000344"></a>
1077
1065
 
1078
1066
  <div class="method-heading">
1079
- <a href="#M000330" class="method-signature">
1067
+ <a href="#M000344" class="method-signature">
1080
1068
  <span class="method-name">document.root &rarr; node<br />
1081
1069
  </span>
1082
1070
  </a>
@@ -1087,8 +1075,8 @@ ruby_xml_document_reader(VALUE self)
1087
1075
  Obtain the root node.
1088
1076
  </p>
1089
1077
  <p><a class="source-toggle" href="#"
1090
- onclick="toggleCode('M000330-source');return false;">[Source]</a></p>
1091
- <div class="method-source-code" id="M000330-source">
1078
+ onclick="toggleCode('M000344-source');return false;">[Source]</a></p>
1079
+ <div class="method-source-code" id="M000344-source">
1092
1080
  <pre>
1093
1081
  /*
1094
1082
  * call-seq:
@@ -1104,11 +1092,11 @@ ruby_xml_document_root_get(VALUE self) {
1104
1092
  </div>
1105
1093
  </div>
1106
1094
 
1107
- <div id="method-M000331" class="method-detail">
1108
- <a name="M000331"></a>
1095
+ <div id="method-M000345" class="method-detail">
1096
+ <a name="M000345"></a>
1109
1097
 
1110
1098
  <div class="method-heading">
1111
- <a href="#M000331" class="method-signature">
1099
+ <a href="#M000345" class="method-signature">
1112
1100
  <span class="method-name">document.root = node<br />
1113
1101
  </span>
1114
1102
  </a>
@@ -1119,8 +1107,8 @@ ruby_xml_document_root_get(VALUE self) {
1119
1107
  Set the root node.
1120
1108
  </p>
1121
1109
  <p><a class="source-toggle" href="#"
1122
- onclick="toggleCode('M000331-source');return false;">[Source]</a></p>
1123
- <div class="method-source-code" id="M000331-source">
1110
+ onclick="toggleCode('M000345-source');return false;">[Source]</a></p>
1111
+ <div class="method-source-code" id="M000345-source">
1124
1112
  <pre>
1125
1113
  /*
1126
1114
  * call-seq:
@@ -1136,12 +1124,12 @@ ruby_xml_document_root_set(VALUE self, VALUE node) {
1136
1124
  </div>
1137
1125
  </div>
1138
1126
 
1139
- <div id="method-M000332" class="method-detail">
1140
- <a name="M000332"></a>
1127
+ <div id="method-M000346" class="method-detail">
1128
+ <a name="M000346"></a>
1141
1129
 
1142
1130
  <div class="method-heading">
1143
- <a href="#M000332" class="method-signature">
1144
- <span class="method-name">document.save(format = false)<br />
1131
+ <a href="#M000346" class="method-signature">
1132
+ <span class="method-name">document.save(filename, format = false) &rarr; int<br />
1145
1133
  </span>
1146
1134
  </a>
1147
1135
  </div>
@@ -1151,16 +1139,29 @@ ruby_xml_document_root_set(VALUE self, VALUE node) {
1151
1139
  Save this document to the file given by filename, optionally formatting the
1152
1140
  output.
1153
1141
  </p>
1142
+ <p>
1143
+ Parameters:
1144
+ </p>
1145
+ <pre>
1146
+ filename: The filename or URL of the new document
1147
+ format: Specifies whether formatting spaces should be added.
1148
+ returns: The number of bytes written or -1 in case of error.
1149
+ </pre>
1154
1150
  <p><a class="source-toggle" href="#"
1155
- onclick="toggleCode('M000332-source');return false;">[Source]</a></p>
1156
- <div class="method-source-code" id="M000332-source">
1151
+ onclick="toggleCode('M000346-source');return false;">[Source]</a></p>
1152
+ <div class="method-source-code" id="M000346-source">
1157
1153
  <pre>
1158
1154
  /*
1159
1155
  * call-seq:
1160
- * document.save(format = false)
1156
+ * document.save(filename, format = false) -&gt; int
1161
1157
  *
1162
1158
  * Save this document to the file given by filename,
1163
1159
  * optionally formatting the output.
1160
+
1161
+ * Parameters:
1162
+ * filename: The filename or URL of the new document
1163
+ * format: Specifies whether formatting spaces should be added.
1164
+ * returns: The number of bytes written or -1 in case of error.
1164
1165
  */
1165
1166
  VALUE
1166
1167
  ruby_xml_document_save(int argc, VALUE *argv, VALUE self) {
@@ -1170,11 +1171,11 @@ ruby_xml_document_save(int argc, VALUE *argv, VALUE self) {
1170
1171
  </div>
1171
1172
  </div>
1172
1173
 
1173
- <div id="method-M000333" class="method-detail">
1174
- <a name="M000333"></a>
1174
+ <div id="method-M000347" class="method-detail">
1175
+ <a name="M000347"></a>
1175
1176
 
1176
1177
  <div class="method-heading">
1177
- <a href="#M000333" class="method-signature">
1178
+ <a href="#M000347" class="method-signature">
1178
1179
  <span class="method-name">document.standalone? &rarr; (true|false)<br />
1179
1180
  </span>
1180
1181
  </a>
@@ -1185,8 +1186,8 @@ ruby_xml_document_save(int argc, VALUE *argv, VALUE self) {
1185
1186
  Determine whether this is a standalone document.
1186
1187
  </p>
1187
1188
  <p><a class="source-toggle" href="#"
1188
- onclick="toggleCode('M000333-source');return false;">[Source]</a></p>
1189
- <div class="method-source-code" id="M000333-source">
1189
+ onclick="toggleCode('M000347-source');return false;">[Source]</a></p>
1190
+ <div class="method-source-code" id="M000347-source">
1190
1191
  <pre>
1191
1192
  /*
1192
1193
  * call-seq:
@@ -1202,11 +1203,11 @@ ruby_xml_document_standalone_q(VALUE self) {
1202
1203
  </div>
1203
1204
  </div>
1204
1205
 
1205
- <div id="method-M000334" class="method-detail">
1206
- <a name="M000334"></a>
1206
+ <div id="method-M000348" class="method-detail">
1207
+ <a name="M000348"></a>
1207
1208
 
1208
1209
  <div class="method-heading">
1209
- <a href="#M000334" class="method-signature">
1210
+ <a href="#M000348" class="method-signature">
1210
1211
  <span class="method-name">document.to_s({format=true,encoding) &rarr; "xml"<br />
1211
1212
  </span>
1212
1213
  </a>
@@ -1216,16 +1217,16 @@ ruby_xml_document_standalone_q(VALUE self) {
1216
1217
  <p>
1217
1218
  Coerce this document to a string representation of it&#8217;s <a
1218
1219
  href="../XML.html">XML</a>. The default is to pretty format, but this
1219
- depends <a href="Parser.html#M000045">Parser#indent_tree_output</a>==true
1220
- or <a href="Parser.html#M000027">Parser#default_keep_blanks</a>==false.
1220
+ depends <a href="Parser.html#M000061">Parser#indent_tree_output</a>==true
1221
+ or <a href="Parser.html#M000043">Parser#default_keep_blanks</a>==false.
1221
1222
  </p>
1222
1223
  <p>
1223
1224
  The encoding is not applied to the document, but is encoding target of the
1224
1225
  resulting string.
1225
1226
  </p>
1226
1227
  <p><a class="source-toggle" href="#"
1227
- onclick="toggleCode('M000334-source');return false;">[Source]</a></p>
1228
- <div class="method-source-code" id="M000334-source">
1228
+ onclick="toggleCode('M000348-source');return false;">[Source]</a></p>
1229
+ <div class="method-source-code" id="M000348-source">
1229
1230
  <pre>
1230
1231
  /*
1231
1232
  * call-seq:
@@ -1247,11 +1248,11 @@ ruby_xml_document_to_s(int argc, VALUE *argv, VALUE self) {
1247
1248
  </div>
1248
1249
  </div>
1249
1250
 
1250
- <div id="method-M000335" class="method-detail">
1251
- <a name="M000335"></a>
1251
+ <div id="method-M000349" class="method-detail">
1252
+ <a name="M000349"></a>
1252
1253
 
1253
1254
  <div class="method-heading">
1254
- <a href="#M000335" class="method-signature">
1255
+ <a href="#M000349" class="method-signature">
1255
1256
  <span class="method-name">document.url &rarr; "url"<br />
1256
1257
  </span>
1257
1258
  </a>
@@ -1262,8 +1263,8 @@ ruby_xml_document_to_s(int argc, VALUE *argv, VALUE self) {
1262
1263
  Obtain this document&#8217;s source URL, if any.
1263
1264
  </p>
1264
1265
  <p><a class="source-toggle" href="#"
1265
- onclick="toggleCode('M000335-source');return false;">[Source]</a></p>
1266
- <div class="method-source-code" id="M000335-source">
1266
+ onclick="toggleCode('M000349-source');return false;">[Source]</a></p>
1267
+ <div class="method-source-code" id="M000349-source">
1267
1268
  <pre>
1268
1269
  /*
1269
1270
  * call-seq:
@@ -1279,11 +1280,11 @@ ruby_xml_document_url_get(VALUE self) {
1279
1280
  </div>
1280
1281
  </div>
1281
1282
 
1282
- <div id="method-M000338" class="method-detail">
1283
- <a name="M000338"></a>
1283
+ <div id="method-M000352" class="method-detail">
1284
+ <a name="M000352"></a>
1284
1285
 
1285
1286
  <div class="method-heading">
1286
- <a href="#M000338" class="method-signature">
1287
+ <a href="#M000352" class="method-signature">
1287
1288
  <span class="method-name">document.validate(dtd) &rarr; (true|false)<br />
1288
1289
  </span>
1289
1290
  </a>
@@ -1294,8 +1295,8 @@ ruby_xml_document_url_get(VALUE self) {
1294
1295
  Validate this document against the specified XML::DTD.
1295
1296
  </p>
1296
1297
  <p><a class="source-toggle" href="#"
1297
- onclick="toggleCode('M000338-source');return false;">[Source]</a></p>
1298
- <div class="method-source-code" id="M000338-source">
1298
+ onclick="toggleCode('M000352-source');return false;">[Source]</a></p>
1299
+ <div class="method-source-code" id="M000352-source">
1299
1300
  <pre>
1300
1301
  /*
1301
1302
  * call-seq:
@@ -1311,11 +1312,11 @@ ruby_xml_document_validate_dtd(VALUE self, VALUE dtd) {
1311
1312
  </div>
1312
1313
  </div>
1313
1314
 
1314
- <div id="method-M000339" class="method-detail">
1315
- <a name="M000339"></a>
1315
+ <div id="method-M000353" class="method-detail">
1316
+ <a name="M000353"></a>
1316
1317
 
1317
1318
  <div class="method-heading">
1318
- <a href="#M000339" class="method-signature">
1319
+ <a href="#M000353" class="method-signature">
1319
1320
  <span class="method-name">document.validate_schema(schema) &rarr; (true|false)<br />
1320
1321
  </span>
1321
1322
  </a>
@@ -1323,11 +1324,12 @@ ruby_xml_document_validate_dtd(VALUE self, VALUE dtd) {
1323
1324
 
1324
1325
  <div class="method-description">
1325
1326
  <p>
1326
- Validate this document against the specified XML::Schema.
1327
+ Validate this document against the specified <a
1328
+ href="Schema.html">XML::Schema</a>.
1327
1329
  </p>
1328
1330
  <p><a class="source-toggle" href="#"
1329
- onclick="toggleCode('M000339-source');return false;">[Source]</a></p>
1330
- <div class="method-source-code" id="M000339-source">
1331
+ onclick="toggleCode('M000353-source');return false;">[Source]</a></p>
1332
+ <div class="method-source-code" id="M000353-source">
1331
1333
  <pre>
1332
1334
  /*
1333
1335
  * call-seq:
@@ -1343,11 +1345,11 @@ ruby_xml_document_validate_schema(VALUE self, VALUE schema) {
1343
1345
  </div>
1344
1346
  </div>
1345
1347
 
1346
- <div id="method-M000336" class="method-detail">
1347
- <a name="M000336"></a>
1348
+ <div id="method-M000350" class="method-detail">
1349
+ <a name="M000350"></a>
1348
1350
 
1349
1351
  <div class="method-heading">
1350
- <a href="#M000336" class="method-signature">
1352
+ <a href="#M000350" class="method-signature">
1351
1353
  <span class="method-name">document.version &rarr; "version"<br />
1352
1354
  </span>
1353
1355
  </a>
@@ -1359,8 +1361,8 @@ Obtain the <a href="../XML.html">XML</a> version specified by this
1359
1361
  document.
1360
1362
  </p>
1361
1363
  <p><a class="source-toggle" href="#"
1362
- onclick="toggleCode('M000336-source');return false;">[Source]</a></p>
1363
- <div class="method-source-code" id="M000336-source">
1364
+ onclick="toggleCode('M000350-source');return false;">[Source]</a></p>
1365
+ <div class="method-source-code" id="M000350-source">
1364
1366
  <pre>
1365
1367
  /*
1366
1368
  * call-seq:
@@ -1376,11 +1378,11 @@ ruby_xml_document_version_get(VALUE self) {
1376
1378
  </div>
1377
1379
  </div>
1378
1380
 
1379
- <div id="method-M000337" class="method-detail">
1380
- <a name="M000337"></a>
1381
+ <div id="method-M000351" class="method-detail">
1382
+ <a name="M000351"></a>
1381
1383
 
1382
1384
  <div class="method-heading">
1383
- <a href="#M000337" class="method-signature">
1385
+ <a href="#M000351" class="method-signature">
1384
1386
  <span class="method-name">document.xinclude &rarr; num<br />
1385
1387
  </span>
1386
1388
  </a>
@@ -1391,8 +1393,8 @@ ruby_xml_document_version_get(VALUE self) {
1391
1393
  Process xinclude directives in this document.
1392
1394
  </p>
1393
1395
  <p><a class="source-toggle" href="#"
1394
- onclick="toggleCode('M000337-source');return false;">[Source]</a></p>
1395
- <div class="method-source-code" id="M000337-source">
1396
+ onclick="toggleCode('M000351-source');return false;">[Source]</a></p>
1397
+ <div class="method-source-code" id="M000351-source">
1396
1398
  <pre>
1397
1399
  /*
1398
1400
  * call-seq: