nokogiri 1.16.7-x64-mingw32 → 1.17.0-x64-mingw32
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +11 -21
- data/README.md +4 -0
- data/dependencies.yml +6 -6
- data/ext/nokogiri/extconf.rb +191 -137
- data/ext/nokogiri/gumbo.c +69 -53
- data/ext/nokogiri/html4_document.c +10 -4
- data/ext/nokogiri/html4_element_description.c +18 -18
- data/ext/nokogiri/html4_sax_parser.c +40 -0
- data/ext/nokogiri/html4_sax_parser_context.c +48 -58
- data/ext/nokogiri/html4_sax_push_parser.c +25 -24
- data/ext/nokogiri/include/libexslt/exsltconfig.h +3 -3
- data/ext/nokogiri/include/libxml2/libxml/HTMLparser.h +12 -19
- data/ext/nokogiri/include/libxml2/libxml/c14n.h +1 -12
- data/ext/nokogiri/include/libxml2/libxml/debugXML.h +1 -1
- data/ext/nokogiri/include/libxml2/libxml/encoding.h +9 -0
- data/ext/nokogiri/include/libxml2/libxml/entities.h +12 -1
- data/ext/nokogiri/include/libxml2/libxml/hash.h +19 -0
- data/ext/nokogiri/include/libxml2/libxml/list.h +2 -2
- data/ext/nokogiri/include/libxml2/libxml/nanohttp.h +17 -0
- data/ext/nokogiri/include/libxml2/libxml/parser.h +60 -54
- data/ext/nokogiri/include/libxml2/libxml/parserInternals.h +9 -1
- data/ext/nokogiri/include/libxml2/libxml/pattern.h +6 -0
- data/ext/nokogiri/include/libxml2/libxml/tree.h +32 -12
- data/ext/nokogiri/include/libxml2/libxml/uri.h +11 -0
- data/ext/nokogiri/include/libxml2/libxml/valid.h +29 -2
- data/ext/nokogiri/include/libxml2/libxml/xinclude.h +7 -0
- data/ext/nokogiri/include/libxml2/libxml/xmlIO.h +21 -4
- data/ext/nokogiri/include/libxml2/libxml/xmlerror.h +14 -0
- data/ext/nokogiri/include/libxml2/libxml/xmlexports.h +111 -15
- data/ext/nokogiri/include/libxml2/libxml/xmlmemory.h +8 -45
- data/ext/nokogiri/include/libxml2/libxml/xmlreader.h +2 -0
- data/ext/nokogiri/include/libxml2/libxml/xmlsave.h +5 -0
- data/ext/nokogiri/include/libxml2/libxml/xmlunicode.h +165 -1
- data/ext/nokogiri/include/libxml2/libxml/xmlversion.h +7 -171
- data/ext/nokogiri/include/libxml2/libxml/xmlwriter.h +1 -0
- data/ext/nokogiri/include/libxml2/libxml/xpath.h +4 -0
- data/ext/nokogiri/include/libxslt/xsltInternals.h +3 -0
- data/ext/nokogiri/include/libxslt/xsltconfig.h +4 -37
- data/ext/nokogiri/libxml2_polyfill.c +114 -0
- data/ext/nokogiri/nokogiri.c +9 -2
- data/ext/nokogiri/nokogiri.h +18 -33
- data/ext/nokogiri/xml_attr.c +1 -1
- data/ext/nokogiri/xml_cdata.c +2 -10
- data/ext/nokogiri/xml_comment.c +3 -8
- data/ext/nokogiri/xml_document.c +163 -156
- data/ext/nokogiri/xml_document_fragment.c +10 -25
- data/ext/nokogiri/xml_dtd.c +1 -1
- data/ext/nokogiri/xml_element_content.c +9 -9
- data/ext/nokogiri/xml_encoding_handler.c +4 -4
- data/ext/nokogiri/xml_namespace.c +6 -6
- data/ext/nokogiri/xml_node.c +137 -105
- data/ext/nokogiri/xml_node_set.c +46 -44
- data/ext/nokogiri/xml_reader.c +54 -58
- data/ext/nokogiri/xml_relax_ng.c +35 -56
- data/ext/nokogiri/xml_sax_parser.c +156 -88
- data/ext/nokogiri/xml_sax_parser_context.c +213 -131
- data/ext/nokogiri/xml_sax_push_parser.c +68 -49
- data/ext/nokogiri/xml_schema.c +50 -85
- data/ext/nokogiri/xml_syntax_error.c +19 -11
- data/ext/nokogiri/xml_text.c +2 -4
- data/ext/nokogiri/xml_xpath_context.c +2 -2
- data/ext/nokogiri/xslt_stylesheet.c +8 -8
- data/lib/nokogiri/3.0/nokogiri.so +0 -0
- data/lib/nokogiri/class_resolver.rb +1 -1
- data/lib/nokogiri/css/node.rb +6 -2
- data/lib/nokogiri/css/parser.rb +6 -4
- data/lib/nokogiri/css/parser.y +2 -2
- data/lib/nokogiri/css/parser_extras.rb +6 -66
- data/lib/nokogiri/css/selector_cache.rb +38 -0
- data/lib/nokogiri/css/tokenizer.rb +4 -4
- data/lib/nokogiri/css/tokenizer.rex +9 -8
- data/lib/nokogiri/css/xpath_visitor.rb +42 -6
- data/lib/nokogiri/css.rb +86 -20
- data/lib/nokogiri/decorators/slop.rb +3 -5
- data/lib/nokogiri/encoding_handler.rb +2 -2
- data/lib/nokogiri/html4/document.rb +44 -23
- data/lib/nokogiri/html4/document_fragment.rb +124 -12
- data/lib/nokogiri/html4/encoding_reader.rb +1 -1
- data/lib/nokogiri/html4/sax/parser.rb +23 -38
- data/lib/nokogiri/html4/sax/parser_context.rb +4 -9
- data/lib/nokogiri/html4.rb +9 -14
- data/lib/nokogiri/html5/builder.rb +40 -0
- data/lib/nokogiri/html5/document.rb +61 -30
- data/lib/nokogiri/html5/document_fragment.rb +130 -20
- data/lib/nokogiri/html5/node.rb +4 -4
- data/lib/nokogiri/html5.rb +114 -72
- data/lib/nokogiri/version/constant.rb +1 -1
- data/lib/nokogiri/xml/builder.rb +8 -1
- data/lib/nokogiri/xml/document.rb +70 -26
- data/lib/nokogiri/xml/document_fragment.rb +84 -13
- data/lib/nokogiri/xml/node.rb +82 -11
- data/lib/nokogiri/xml/node_set.rb +9 -7
- data/lib/nokogiri/xml/parse_options.rb +1 -1
- data/lib/nokogiri/xml/pp/node.rb +6 -1
- data/lib/nokogiri/xml/reader.rb +46 -13
- data/lib/nokogiri/xml/relax_ng.rb +57 -20
- data/lib/nokogiri/xml/sax/document.rb +174 -83
- data/lib/nokogiri/xml/sax/parser.rb +115 -41
- data/lib/nokogiri/xml/sax/parser_context.rb +116 -8
- data/lib/nokogiri/xml/sax/push_parser.rb +3 -0
- data/lib/nokogiri/xml/sax.rb +48 -0
- data/lib/nokogiri/xml/schema.rb +112 -45
- data/lib/nokogiri/xml/searchable.rb +6 -8
- data/lib/nokogiri/xml/syntax_error.rb +22 -0
- data/lib/nokogiri/xml.rb +13 -24
- data/lib/nokogiri/xslt.rb +3 -9
- data/lib/xsd/xmlparser/nokogiri.rb +3 -4
- metadata +8 -5
- data/ext/nokogiri/libxml2_backwards_compat.c +0 -121
@@ -1,121 +0,0 @@
|
|
1
|
-
#ifndef HAVE_XMLFIRSTELEMENTCHILD
|
2
|
-
#include <nokogiri.h>
|
3
|
-
/**
|
4
|
-
* xmlFirstElementChild:
|
5
|
-
* @parent: the parent node
|
6
|
-
*
|
7
|
-
* Finds the first child node of that element which is a Element node
|
8
|
-
* Note the handling of entities references is different than in
|
9
|
-
* the W3C DOM element traversal spec since we don't have back reference
|
10
|
-
* from entities content to entities references.
|
11
|
-
*
|
12
|
-
* Returns the first element child or NULL if not available
|
13
|
-
*/
|
14
|
-
xmlNodePtr
|
15
|
-
xmlFirstElementChild(xmlNodePtr parent)
|
16
|
-
{
|
17
|
-
xmlNodePtr cur = NULL;
|
18
|
-
|
19
|
-
if (parent == NULL) {
|
20
|
-
return (NULL);
|
21
|
-
}
|
22
|
-
switch (parent->type) {
|
23
|
-
case XML_ELEMENT_NODE:
|
24
|
-
case XML_ENTITY_NODE:
|
25
|
-
case XML_DOCUMENT_NODE:
|
26
|
-
case XML_HTML_DOCUMENT_NODE:
|
27
|
-
cur = parent->children;
|
28
|
-
break;
|
29
|
-
default:
|
30
|
-
return (NULL);
|
31
|
-
}
|
32
|
-
while (cur != NULL) {
|
33
|
-
if (cur->type == XML_ELEMENT_NODE) {
|
34
|
-
return (cur);
|
35
|
-
}
|
36
|
-
cur = cur->next;
|
37
|
-
}
|
38
|
-
return (NULL);
|
39
|
-
}
|
40
|
-
|
41
|
-
/**
|
42
|
-
* xmlNextElementSibling:
|
43
|
-
* @node: the current node
|
44
|
-
*
|
45
|
-
* Finds the first closest next sibling of the node which is an
|
46
|
-
* element node.
|
47
|
-
* Note the handling of entities references is different than in
|
48
|
-
* the W3C DOM element traversal spec since we don't have back reference
|
49
|
-
* from entities content to entities references.
|
50
|
-
*
|
51
|
-
* Returns the next element sibling or NULL if not available
|
52
|
-
*/
|
53
|
-
xmlNodePtr
|
54
|
-
xmlNextElementSibling(xmlNodePtr node)
|
55
|
-
{
|
56
|
-
if (node == NULL) {
|
57
|
-
return (NULL);
|
58
|
-
}
|
59
|
-
switch (node->type) {
|
60
|
-
case XML_ELEMENT_NODE:
|
61
|
-
case XML_TEXT_NODE:
|
62
|
-
case XML_CDATA_SECTION_NODE:
|
63
|
-
case XML_ENTITY_REF_NODE:
|
64
|
-
case XML_ENTITY_NODE:
|
65
|
-
case XML_PI_NODE:
|
66
|
-
case XML_COMMENT_NODE:
|
67
|
-
case XML_DTD_NODE:
|
68
|
-
case XML_XINCLUDE_START:
|
69
|
-
case XML_XINCLUDE_END:
|
70
|
-
node = node->next;
|
71
|
-
break;
|
72
|
-
default:
|
73
|
-
return (NULL);
|
74
|
-
}
|
75
|
-
while (node != NULL) {
|
76
|
-
if (node->type == XML_ELEMENT_NODE) {
|
77
|
-
return (node);
|
78
|
-
}
|
79
|
-
node = node->next;
|
80
|
-
}
|
81
|
-
return (NULL);
|
82
|
-
}
|
83
|
-
|
84
|
-
/**
|
85
|
-
* xmlLastElementChild:
|
86
|
-
* @parent: the parent node
|
87
|
-
*
|
88
|
-
* Finds the last child node of that element which is a Element node
|
89
|
-
* Note the handling of entities references is different than in
|
90
|
-
* the W3C DOM element traversal spec since we don't have back reference
|
91
|
-
* from entities content to entities references.
|
92
|
-
*
|
93
|
-
* Returns the last element child or NULL if not available
|
94
|
-
*/
|
95
|
-
xmlNodePtr
|
96
|
-
xmlLastElementChild(xmlNodePtr parent)
|
97
|
-
{
|
98
|
-
xmlNodePtr cur = NULL;
|
99
|
-
|
100
|
-
if (parent == NULL) {
|
101
|
-
return (NULL);
|
102
|
-
}
|
103
|
-
switch (parent->type) {
|
104
|
-
case XML_ELEMENT_NODE:
|
105
|
-
case XML_ENTITY_NODE:
|
106
|
-
case XML_DOCUMENT_NODE:
|
107
|
-
case XML_HTML_DOCUMENT_NODE:
|
108
|
-
cur = parent->last;
|
109
|
-
break;
|
110
|
-
default:
|
111
|
-
return (NULL);
|
112
|
-
}
|
113
|
-
while (cur != NULL) {
|
114
|
-
if (cur->type == XML_ELEMENT_NODE) {
|
115
|
-
return (cur);
|
116
|
-
}
|
117
|
-
cur = cur->prev;
|
118
|
-
}
|
119
|
-
return (NULL);
|
120
|
-
}
|
121
|
-
#endif
|