nokogiri 1.18.0.rc1-aarch64-linux-musl
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/Gemfile +38 -0
- data/LICENSE-DEPENDENCIES.md +2224 -0
- data/LICENSE.md +9 -0
- data/README.md +293 -0
- data/bin/nokogiri +131 -0
- data/dependencies.yml +42 -0
- data/ext/nokogiri/depend +38 -0
- data/ext/nokogiri/extconf.rb +1173 -0
- data/ext/nokogiri/gumbo.c +610 -0
- data/ext/nokogiri/html4_document.c +171 -0
- data/ext/nokogiri/html4_element_description.c +299 -0
- data/ext/nokogiri/html4_entity_lookup.c +37 -0
- data/ext/nokogiri/html4_sax_parser.c +40 -0
- data/ext/nokogiri/html4_sax_parser_context.c +98 -0
- data/ext/nokogiri/html4_sax_push_parser.c +96 -0
- data/ext/nokogiri/include/libexslt/exslt.h +108 -0
- data/ext/nokogiri/include/libexslt/exsltconfig.h +70 -0
- data/ext/nokogiri/include/libexslt/exsltexports.h +63 -0
- data/ext/nokogiri/include/libxml2/libxml/HTMLparser.h +336 -0
- data/ext/nokogiri/include/libxml2/libxml/HTMLtree.h +147 -0
- data/ext/nokogiri/include/libxml2/libxml/SAX.h +202 -0
- data/ext/nokogiri/include/libxml2/libxml/SAX2.h +171 -0
- data/ext/nokogiri/include/libxml2/libxml/c14n.h +115 -0
- data/ext/nokogiri/include/libxml2/libxml/catalog.h +182 -0
- data/ext/nokogiri/include/libxml2/libxml/chvalid.h +230 -0
- data/ext/nokogiri/include/libxml2/libxml/debugXML.h +217 -0
- data/ext/nokogiri/include/libxml2/libxml/dict.h +82 -0
- data/ext/nokogiri/include/libxml2/libxml/encoding.h +244 -0
- data/ext/nokogiri/include/libxml2/libxml/entities.h +166 -0
- data/ext/nokogiri/include/libxml2/libxml/globals.h +41 -0
- data/ext/nokogiri/include/libxml2/libxml/hash.h +251 -0
- data/ext/nokogiri/include/libxml2/libxml/list.h +137 -0
- data/ext/nokogiri/include/libxml2/libxml/nanoftp.h +186 -0
- data/ext/nokogiri/include/libxml2/libxml/nanohttp.h +98 -0
- data/ext/nokogiri/include/libxml2/libxml/parser.h +1390 -0
- data/ext/nokogiri/include/libxml2/libxml/parserInternals.h +671 -0
- data/ext/nokogiri/include/libxml2/libxml/pattern.h +106 -0
- data/ext/nokogiri/include/libxml2/libxml/relaxng.h +219 -0
- data/ext/nokogiri/include/libxml2/libxml/schemasInternals.h +959 -0
- data/ext/nokogiri/include/libxml2/libxml/schematron.h +143 -0
- data/ext/nokogiri/include/libxml2/libxml/threads.h +87 -0
- data/ext/nokogiri/include/libxml2/libxml/tree.h +1382 -0
- data/ext/nokogiri/include/libxml2/libxml/uri.h +106 -0
- data/ext/nokogiri/include/libxml2/libxml/valid.h +477 -0
- data/ext/nokogiri/include/libxml2/libxml/xinclude.h +136 -0
- data/ext/nokogiri/include/libxml2/libxml/xlink.h +189 -0
- data/ext/nokogiri/include/libxml2/libxml/xmlIO.h +438 -0
- data/ext/nokogiri/include/libxml2/libxml/xmlautomata.h +146 -0
- data/ext/nokogiri/include/libxml2/libxml/xmlerror.h +962 -0
- data/ext/nokogiri/include/libxml2/libxml/xmlexports.h +146 -0
- data/ext/nokogiri/include/libxml2/libxml/xmlmemory.h +188 -0
- data/ext/nokogiri/include/libxml2/libxml/xmlmodule.h +57 -0
- data/ext/nokogiri/include/libxml2/libxml/xmlreader.h +436 -0
- data/ext/nokogiri/include/libxml2/libxml/xmlregexp.h +215 -0
- data/ext/nokogiri/include/libxml2/libxml/xmlsave.h +102 -0
- data/ext/nokogiri/include/libxml2/libxml/xmlschemas.h +249 -0
- data/ext/nokogiri/include/libxml2/libxml/xmlschemastypes.h +152 -0
- data/ext/nokogiri/include/libxml2/libxml/xmlstring.h +140 -0
- data/ext/nokogiri/include/libxml2/libxml/xmlunicode.h +366 -0
- data/ext/nokogiri/include/libxml2/libxml/xmlversion.h +347 -0
- data/ext/nokogiri/include/libxml2/libxml/xmlwriter.h +489 -0
- data/ext/nokogiri/include/libxml2/libxml/xpath.h +579 -0
- data/ext/nokogiri/include/libxml2/libxml/xpathInternals.h +633 -0
- data/ext/nokogiri/include/libxml2/libxml/xpointer.h +138 -0
- data/ext/nokogiri/include/libxslt/attributes.h +39 -0
- data/ext/nokogiri/include/libxslt/documents.h +93 -0
- data/ext/nokogiri/include/libxslt/extensions.h +262 -0
- data/ext/nokogiri/include/libxslt/extra.h +72 -0
- data/ext/nokogiri/include/libxslt/functions.h +78 -0
- data/ext/nokogiri/include/libxslt/imports.h +75 -0
- data/ext/nokogiri/include/libxslt/keys.h +53 -0
- data/ext/nokogiri/include/libxslt/namespaces.h +68 -0
- data/ext/nokogiri/include/libxslt/numbersInternals.h +73 -0
- data/ext/nokogiri/include/libxslt/pattern.h +84 -0
- data/ext/nokogiri/include/libxslt/preproc.h +43 -0
- data/ext/nokogiri/include/libxslt/security.h +104 -0
- data/ext/nokogiri/include/libxslt/templates.h +77 -0
- data/ext/nokogiri/include/libxslt/transform.h +207 -0
- data/ext/nokogiri/include/libxslt/variables.h +118 -0
- data/ext/nokogiri/include/libxslt/xslt.h +110 -0
- data/ext/nokogiri/include/libxslt/xsltInternals.h +1995 -0
- data/ext/nokogiri/include/libxslt/xsltconfig.h +146 -0
- data/ext/nokogiri/include/libxslt/xsltexports.h +64 -0
- data/ext/nokogiri/include/libxslt/xsltlocale.h +44 -0
- data/ext/nokogiri/include/libxslt/xsltutils.h +343 -0
- data/ext/nokogiri/libxml2_polyfill.c +114 -0
- data/ext/nokogiri/nokogiri.c +294 -0
- data/ext/nokogiri/nokogiri.h +238 -0
- data/ext/nokogiri/test_global_handlers.c +40 -0
- data/ext/nokogiri/xml_attr.c +103 -0
- data/ext/nokogiri/xml_attribute_decl.c +70 -0
- data/ext/nokogiri/xml_cdata.c +62 -0
- data/ext/nokogiri/xml_comment.c +57 -0
- data/ext/nokogiri/xml_document.c +784 -0
- data/ext/nokogiri/xml_document_fragment.c +29 -0
- data/ext/nokogiri/xml_dtd.c +208 -0
- data/ext/nokogiri/xml_element_content.c +131 -0
- data/ext/nokogiri/xml_element_decl.c +69 -0
- data/ext/nokogiri/xml_encoding_handler.c +112 -0
- data/ext/nokogiri/xml_entity_decl.c +112 -0
- data/ext/nokogiri/xml_entity_reference.c +50 -0
- data/ext/nokogiri/xml_namespace.c +181 -0
- data/ext/nokogiri/xml_node.c +2459 -0
- data/ext/nokogiri/xml_node_set.c +518 -0
- data/ext/nokogiri/xml_processing_instruction.c +54 -0
- data/ext/nokogiri/xml_reader.c +777 -0
- data/ext/nokogiri/xml_relax_ng.c +149 -0
- data/ext/nokogiri/xml_sax_parser.c +403 -0
- data/ext/nokogiri/xml_sax_parser_context.c +390 -0
- data/ext/nokogiri/xml_sax_push_parser.c +206 -0
- data/ext/nokogiri/xml_schema.c +226 -0
- data/ext/nokogiri/xml_syntax_error.c +93 -0
- data/ext/nokogiri/xml_text.c +59 -0
- data/ext/nokogiri/xml_xpath_context.c +502 -0
- data/ext/nokogiri/xslt_stylesheet.c +421 -0
- data/gumbo-parser/CHANGES.md +63 -0
- data/gumbo-parser/Makefile +129 -0
- data/gumbo-parser/THANKS +27 -0
- data/lib/nokogiri/3.1/nokogiri.so +0 -0
- data/lib/nokogiri/3.2/nokogiri.so +0 -0
- data/lib/nokogiri/3.3/nokogiri.so +0 -0
- data/lib/nokogiri/3.4/nokogiri.so +0 -0
- data/lib/nokogiri/class_resolver.rb +67 -0
- data/lib/nokogiri/css/node.rb +58 -0
- data/lib/nokogiri/css/parser.rb +772 -0
- data/lib/nokogiri/css/parser.y +277 -0
- data/lib/nokogiri/css/parser_extras.rb +36 -0
- data/lib/nokogiri/css/selector_cache.rb +38 -0
- data/lib/nokogiri/css/syntax_error.rb +9 -0
- data/lib/nokogiri/css/tokenizer.rb +155 -0
- data/lib/nokogiri/css/tokenizer.rex +57 -0
- data/lib/nokogiri/css/xpath_visitor.rb +375 -0
- data/lib/nokogiri/css.rb +132 -0
- data/lib/nokogiri/decorators/slop.rb +42 -0
- data/lib/nokogiri/encoding_handler.rb +57 -0
- data/lib/nokogiri/extension.rb +32 -0
- data/lib/nokogiri/gumbo.rb +15 -0
- data/lib/nokogiri/html.rb +48 -0
- data/lib/nokogiri/html4/builder.rb +37 -0
- data/lib/nokogiri/html4/document.rb +235 -0
- data/lib/nokogiri/html4/document_fragment.rb +166 -0
- data/lib/nokogiri/html4/element_description.rb +25 -0
- data/lib/nokogiri/html4/element_description_defaults.rb +2040 -0
- data/lib/nokogiri/html4/encoding_reader.rb +121 -0
- data/lib/nokogiri/html4/entity_lookup.rb +15 -0
- data/lib/nokogiri/html4/sax/parser.rb +48 -0
- data/lib/nokogiri/html4/sax/parser_context.rb +15 -0
- data/lib/nokogiri/html4/sax/push_parser.rb +37 -0
- data/lib/nokogiri/html4.rb +42 -0
- data/lib/nokogiri/html5/builder.rb +40 -0
- data/lib/nokogiri/html5/document.rb +199 -0
- data/lib/nokogiri/html5/document_fragment.rb +200 -0
- data/lib/nokogiri/html5/node.rb +103 -0
- data/lib/nokogiri/html5.rb +368 -0
- data/lib/nokogiri/jruby/dependencies.rb +3 -0
- data/lib/nokogiri/jruby/nokogiri_jars.rb +43 -0
- data/lib/nokogiri/syntax_error.rb +6 -0
- data/lib/nokogiri/version/constant.rb +6 -0
- data/lib/nokogiri/version/info.rb +224 -0
- data/lib/nokogiri/version.rb +4 -0
- data/lib/nokogiri/xml/attr.rb +66 -0
- data/lib/nokogiri/xml/attribute_decl.rb +22 -0
- data/lib/nokogiri/xml/builder.rb +494 -0
- data/lib/nokogiri/xml/cdata.rb +13 -0
- data/lib/nokogiri/xml/character_data.rb +9 -0
- data/lib/nokogiri/xml/document.rb +514 -0
- data/lib/nokogiri/xml/document_fragment.rb +276 -0
- data/lib/nokogiri/xml/dtd.rb +34 -0
- data/lib/nokogiri/xml/element_content.rb +46 -0
- data/lib/nokogiri/xml/element_decl.rb +17 -0
- data/lib/nokogiri/xml/entity_decl.rb +23 -0
- data/lib/nokogiri/xml/entity_reference.rb +20 -0
- data/lib/nokogiri/xml/namespace.rb +57 -0
- data/lib/nokogiri/xml/node/save_options.rb +76 -0
- data/lib/nokogiri/xml/node.rb +1650 -0
- data/lib/nokogiri/xml/node_set.rb +449 -0
- data/lib/nokogiri/xml/notation.rb +19 -0
- data/lib/nokogiri/xml/parse_options.rb +213 -0
- data/lib/nokogiri/xml/pp/character_data.rb +21 -0
- data/lib/nokogiri/xml/pp/node.rb +73 -0
- data/lib/nokogiri/xml/pp.rb +4 -0
- data/lib/nokogiri/xml/processing_instruction.rb +11 -0
- data/lib/nokogiri/xml/reader.rb +139 -0
- data/lib/nokogiri/xml/relax_ng.rb +75 -0
- data/lib/nokogiri/xml/sax/document.rb +258 -0
- data/lib/nokogiri/xml/sax/parser.rb +199 -0
- data/lib/nokogiri/xml/sax/parser_context.rb +129 -0
- data/lib/nokogiri/xml/sax/push_parser.rb +64 -0
- data/lib/nokogiri/xml/sax.rb +54 -0
- data/lib/nokogiri/xml/schema.rb +140 -0
- data/lib/nokogiri/xml/searchable.rb +297 -0
- data/lib/nokogiri/xml/syntax_error.rb +94 -0
- data/lib/nokogiri/xml/text.rb +11 -0
- data/lib/nokogiri/xml/xpath/syntax_error.rb +13 -0
- data/lib/nokogiri/xml/xpath.rb +21 -0
- data/lib/nokogiri/xml/xpath_context.rb +49 -0
- data/lib/nokogiri/xml.rb +65 -0
- data/lib/nokogiri/xslt/stylesheet.rb +49 -0
- data/lib/nokogiri/xslt.rb +129 -0
- data/lib/nokogiri.rb +128 -0
- data/lib/xsd/xmlparser/nokogiri.rb +105 -0
- metadata +324 -0
@@ -0,0 +1,106 @@
|
|
1
|
+
/*
|
2
|
+
* Summary: pattern expression handling
|
3
|
+
* Description: allows to compile and test pattern expressions for nodes
|
4
|
+
* either in a tree or based on a parser state.
|
5
|
+
*
|
6
|
+
* Copy: See Copyright for the status of this software.
|
7
|
+
*
|
8
|
+
* Author: Daniel Veillard
|
9
|
+
*/
|
10
|
+
|
11
|
+
#ifndef __XML_PATTERN_H__
|
12
|
+
#define __XML_PATTERN_H__
|
13
|
+
|
14
|
+
#include <libxml/xmlversion.h>
|
15
|
+
#include <libxml/tree.h>
|
16
|
+
#include <libxml/dict.h>
|
17
|
+
|
18
|
+
#ifdef LIBXML_PATTERN_ENABLED
|
19
|
+
|
20
|
+
#ifdef __cplusplus
|
21
|
+
extern "C" {
|
22
|
+
#endif
|
23
|
+
|
24
|
+
/**
|
25
|
+
* xmlPattern:
|
26
|
+
*
|
27
|
+
* A compiled (XPath based) pattern to select nodes
|
28
|
+
*/
|
29
|
+
typedef struct _xmlPattern xmlPattern;
|
30
|
+
typedef xmlPattern *xmlPatternPtr;
|
31
|
+
|
32
|
+
/**
|
33
|
+
* xmlPatternFlags:
|
34
|
+
*
|
35
|
+
* This is the set of options affecting the behaviour of pattern
|
36
|
+
* matching with this module
|
37
|
+
*
|
38
|
+
*/
|
39
|
+
typedef enum {
|
40
|
+
XML_PATTERN_DEFAULT = 0, /* simple pattern match */
|
41
|
+
XML_PATTERN_XPATH = 1<<0, /* standard XPath pattern */
|
42
|
+
XML_PATTERN_XSSEL = 1<<1, /* XPath subset for schema selector */
|
43
|
+
XML_PATTERN_XSFIELD = 1<<2 /* XPath subset for schema field */
|
44
|
+
} xmlPatternFlags;
|
45
|
+
|
46
|
+
XMLPUBFUN void
|
47
|
+
xmlFreePattern (xmlPatternPtr comp);
|
48
|
+
|
49
|
+
XMLPUBFUN void
|
50
|
+
xmlFreePatternList (xmlPatternPtr comp);
|
51
|
+
|
52
|
+
XMLPUBFUN xmlPatternPtr
|
53
|
+
xmlPatterncompile (const xmlChar *pattern,
|
54
|
+
xmlDict *dict,
|
55
|
+
int flags,
|
56
|
+
const xmlChar **namespaces);
|
57
|
+
XMLPUBFUN int
|
58
|
+
xmlPatternCompileSafe (const xmlChar *pattern,
|
59
|
+
xmlDict *dict,
|
60
|
+
int flags,
|
61
|
+
const xmlChar **namespaces,
|
62
|
+
xmlPatternPtr *patternOut);
|
63
|
+
XMLPUBFUN int
|
64
|
+
xmlPatternMatch (xmlPatternPtr comp,
|
65
|
+
xmlNodePtr node);
|
66
|
+
|
67
|
+
/* streaming interfaces */
|
68
|
+
typedef struct _xmlStreamCtxt xmlStreamCtxt;
|
69
|
+
typedef xmlStreamCtxt *xmlStreamCtxtPtr;
|
70
|
+
|
71
|
+
XMLPUBFUN int
|
72
|
+
xmlPatternStreamable (xmlPatternPtr comp);
|
73
|
+
XMLPUBFUN int
|
74
|
+
xmlPatternMaxDepth (xmlPatternPtr comp);
|
75
|
+
XMLPUBFUN int
|
76
|
+
xmlPatternMinDepth (xmlPatternPtr comp);
|
77
|
+
XMLPUBFUN int
|
78
|
+
xmlPatternFromRoot (xmlPatternPtr comp);
|
79
|
+
XMLPUBFUN xmlStreamCtxtPtr
|
80
|
+
xmlPatternGetStreamCtxt (xmlPatternPtr comp);
|
81
|
+
XMLPUBFUN void
|
82
|
+
xmlFreeStreamCtxt (xmlStreamCtxtPtr stream);
|
83
|
+
XMLPUBFUN int
|
84
|
+
xmlStreamPushNode (xmlStreamCtxtPtr stream,
|
85
|
+
const xmlChar *name,
|
86
|
+
const xmlChar *ns,
|
87
|
+
int nodeType);
|
88
|
+
XMLPUBFUN int
|
89
|
+
xmlStreamPush (xmlStreamCtxtPtr stream,
|
90
|
+
const xmlChar *name,
|
91
|
+
const xmlChar *ns);
|
92
|
+
XMLPUBFUN int
|
93
|
+
xmlStreamPushAttr (xmlStreamCtxtPtr stream,
|
94
|
+
const xmlChar *name,
|
95
|
+
const xmlChar *ns);
|
96
|
+
XMLPUBFUN int
|
97
|
+
xmlStreamPop (xmlStreamCtxtPtr stream);
|
98
|
+
XMLPUBFUN int
|
99
|
+
xmlStreamWantsAnyNode (xmlStreamCtxtPtr stream);
|
100
|
+
#ifdef __cplusplus
|
101
|
+
}
|
102
|
+
#endif
|
103
|
+
|
104
|
+
#endif /* LIBXML_PATTERN_ENABLED */
|
105
|
+
|
106
|
+
#endif /* __XML_PATTERN_H__ */
|
@@ -0,0 +1,219 @@
|
|
1
|
+
/*
|
2
|
+
* Summary: implementation of the Relax-NG validation
|
3
|
+
* Description: implementation of the Relax-NG validation
|
4
|
+
*
|
5
|
+
* Copy: See Copyright for the status of this software.
|
6
|
+
*
|
7
|
+
* Author: Daniel Veillard
|
8
|
+
*/
|
9
|
+
|
10
|
+
#ifndef __XML_RELAX_NG__
|
11
|
+
#define __XML_RELAX_NG__
|
12
|
+
|
13
|
+
#include <libxml/xmlversion.h>
|
14
|
+
#include <libxml/xmlerror.h>
|
15
|
+
#include <libxml/xmlstring.h>
|
16
|
+
#include <libxml/tree.h>
|
17
|
+
|
18
|
+
#ifdef LIBXML_SCHEMAS_ENABLED
|
19
|
+
|
20
|
+
#ifdef __cplusplus
|
21
|
+
extern "C" {
|
22
|
+
#endif
|
23
|
+
|
24
|
+
typedef struct _xmlRelaxNG xmlRelaxNG;
|
25
|
+
typedef xmlRelaxNG *xmlRelaxNGPtr;
|
26
|
+
|
27
|
+
|
28
|
+
/**
|
29
|
+
* xmlRelaxNGValidityErrorFunc:
|
30
|
+
* @ctx: the validation context
|
31
|
+
* @msg: the message
|
32
|
+
* @...: extra arguments
|
33
|
+
*
|
34
|
+
* Signature of an error callback from a Relax-NG validation
|
35
|
+
*/
|
36
|
+
typedef void (*xmlRelaxNGValidityErrorFunc) (void *ctx,
|
37
|
+
const char *msg,
|
38
|
+
...) LIBXML_ATTR_FORMAT(2,3);
|
39
|
+
|
40
|
+
/**
|
41
|
+
* xmlRelaxNGValidityWarningFunc:
|
42
|
+
* @ctx: the validation context
|
43
|
+
* @msg: the message
|
44
|
+
* @...: extra arguments
|
45
|
+
*
|
46
|
+
* Signature of a warning callback from a Relax-NG validation
|
47
|
+
*/
|
48
|
+
typedef void (*xmlRelaxNGValidityWarningFunc) (void *ctx,
|
49
|
+
const char *msg,
|
50
|
+
...) LIBXML_ATTR_FORMAT(2,3);
|
51
|
+
|
52
|
+
/**
|
53
|
+
* A schemas validation context
|
54
|
+
*/
|
55
|
+
typedef struct _xmlRelaxNGParserCtxt xmlRelaxNGParserCtxt;
|
56
|
+
typedef xmlRelaxNGParserCtxt *xmlRelaxNGParserCtxtPtr;
|
57
|
+
|
58
|
+
typedef struct _xmlRelaxNGValidCtxt xmlRelaxNGValidCtxt;
|
59
|
+
typedef xmlRelaxNGValidCtxt *xmlRelaxNGValidCtxtPtr;
|
60
|
+
|
61
|
+
/*
|
62
|
+
* xmlRelaxNGValidErr:
|
63
|
+
*
|
64
|
+
* List of possible Relax NG validation errors
|
65
|
+
*/
|
66
|
+
typedef enum {
|
67
|
+
XML_RELAXNG_OK = 0,
|
68
|
+
XML_RELAXNG_ERR_MEMORY,
|
69
|
+
XML_RELAXNG_ERR_TYPE,
|
70
|
+
XML_RELAXNG_ERR_TYPEVAL,
|
71
|
+
XML_RELAXNG_ERR_DUPID,
|
72
|
+
XML_RELAXNG_ERR_TYPECMP,
|
73
|
+
XML_RELAXNG_ERR_NOSTATE,
|
74
|
+
XML_RELAXNG_ERR_NODEFINE,
|
75
|
+
XML_RELAXNG_ERR_LISTEXTRA,
|
76
|
+
XML_RELAXNG_ERR_LISTEMPTY,
|
77
|
+
XML_RELAXNG_ERR_INTERNODATA,
|
78
|
+
XML_RELAXNG_ERR_INTERSEQ,
|
79
|
+
XML_RELAXNG_ERR_INTEREXTRA,
|
80
|
+
XML_RELAXNG_ERR_ELEMNAME,
|
81
|
+
XML_RELAXNG_ERR_ATTRNAME,
|
82
|
+
XML_RELAXNG_ERR_ELEMNONS,
|
83
|
+
XML_RELAXNG_ERR_ATTRNONS,
|
84
|
+
XML_RELAXNG_ERR_ELEMWRONGNS,
|
85
|
+
XML_RELAXNG_ERR_ATTRWRONGNS,
|
86
|
+
XML_RELAXNG_ERR_ELEMEXTRANS,
|
87
|
+
XML_RELAXNG_ERR_ATTREXTRANS,
|
88
|
+
XML_RELAXNG_ERR_ELEMNOTEMPTY,
|
89
|
+
XML_RELAXNG_ERR_NOELEM,
|
90
|
+
XML_RELAXNG_ERR_NOTELEM,
|
91
|
+
XML_RELAXNG_ERR_ATTRVALID,
|
92
|
+
XML_RELAXNG_ERR_CONTENTVALID,
|
93
|
+
XML_RELAXNG_ERR_EXTRACONTENT,
|
94
|
+
XML_RELAXNG_ERR_INVALIDATTR,
|
95
|
+
XML_RELAXNG_ERR_DATAELEM,
|
96
|
+
XML_RELAXNG_ERR_VALELEM,
|
97
|
+
XML_RELAXNG_ERR_LISTELEM,
|
98
|
+
XML_RELAXNG_ERR_DATATYPE,
|
99
|
+
XML_RELAXNG_ERR_VALUE,
|
100
|
+
XML_RELAXNG_ERR_LIST,
|
101
|
+
XML_RELAXNG_ERR_NOGRAMMAR,
|
102
|
+
XML_RELAXNG_ERR_EXTRADATA,
|
103
|
+
XML_RELAXNG_ERR_LACKDATA,
|
104
|
+
XML_RELAXNG_ERR_INTERNAL,
|
105
|
+
XML_RELAXNG_ERR_ELEMWRONG,
|
106
|
+
XML_RELAXNG_ERR_TEXTWRONG
|
107
|
+
} xmlRelaxNGValidErr;
|
108
|
+
|
109
|
+
/*
|
110
|
+
* xmlRelaxNGParserFlags:
|
111
|
+
*
|
112
|
+
* List of possible Relax NG Parser flags
|
113
|
+
*/
|
114
|
+
typedef enum {
|
115
|
+
XML_RELAXNGP_NONE = 0,
|
116
|
+
XML_RELAXNGP_FREE_DOC = 1,
|
117
|
+
XML_RELAXNGP_CRNG = 2
|
118
|
+
} xmlRelaxNGParserFlag;
|
119
|
+
|
120
|
+
XMLPUBFUN int
|
121
|
+
xmlRelaxNGInitTypes (void);
|
122
|
+
XML_DEPRECATED
|
123
|
+
XMLPUBFUN void
|
124
|
+
xmlRelaxNGCleanupTypes (void);
|
125
|
+
|
126
|
+
/*
|
127
|
+
* Interfaces for parsing.
|
128
|
+
*/
|
129
|
+
XMLPUBFUN xmlRelaxNGParserCtxtPtr
|
130
|
+
xmlRelaxNGNewParserCtxt (const char *URL);
|
131
|
+
XMLPUBFUN xmlRelaxNGParserCtxtPtr
|
132
|
+
xmlRelaxNGNewMemParserCtxt (const char *buffer,
|
133
|
+
int size);
|
134
|
+
XMLPUBFUN xmlRelaxNGParserCtxtPtr
|
135
|
+
xmlRelaxNGNewDocParserCtxt (xmlDocPtr doc);
|
136
|
+
|
137
|
+
XMLPUBFUN int
|
138
|
+
xmlRelaxParserSetFlag (xmlRelaxNGParserCtxtPtr ctxt,
|
139
|
+
int flag);
|
140
|
+
|
141
|
+
XMLPUBFUN void
|
142
|
+
xmlRelaxNGFreeParserCtxt (xmlRelaxNGParserCtxtPtr ctxt);
|
143
|
+
XMLPUBFUN void
|
144
|
+
xmlRelaxNGSetParserErrors(xmlRelaxNGParserCtxtPtr ctxt,
|
145
|
+
xmlRelaxNGValidityErrorFunc err,
|
146
|
+
xmlRelaxNGValidityWarningFunc warn,
|
147
|
+
void *ctx);
|
148
|
+
XMLPUBFUN int
|
149
|
+
xmlRelaxNGGetParserErrors(xmlRelaxNGParserCtxtPtr ctxt,
|
150
|
+
xmlRelaxNGValidityErrorFunc *err,
|
151
|
+
xmlRelaxNGValidityWarningFunc *warn,
|
152
|
+
void **ctx);
|
153
|
+
XMLPUBFUN void
|
154
|
+
xmlRelaxNGSetParserStructuredErrors(
|
155
|
+
xmlRelaxNGParserCtxtPtr ctxt,
|
156
|
+
xmlStructuredErrorFunc serror,
|
157
|
+
void *ctx);
|
158
|
+
XMLPUBFUN xmlRelaxNGPtr
|
159
|
+
xmlRelaxNGParse (xmlRelaxNGParserCtxtPtr ctxt);
|
160
|
+
XMLPUBFUN void
|
161
|
+
xmlRelaxNGFree (xmlRelaxNGPtr schema);
|
162
|
+
#ifdef LIBXML_OUTPUT_ENABLED
|
163
|
+
XMLPUBFUN void
|
164
|
+
xmlRelaxNGDump (FILE *output,
|
165
|
+
xmlRelaxNGPtr schema);
|
166
|
+
XMLPUBFUN void
|
167
|
+
xmlRelaxNGDumpTree (FILE * output,
|
168
|
+
xmlRelaxNGPtr schema);
|
169
|
+
#endif /* LIBXML_OUTPUT_ENABLED */
|
170
|
+
/*
|
171
|
+
* Interfaces for validating
|
172
|
+
*/
|
173
|
+
XMLPUBFUN void
|
174
|
+
xmlRelaxNGSetValidErrors(xmlRelaxNGValidCtxtPtr ctxt,
|
175
|
+
xmlRelaxNGValidityErrorFunc err,
|
176
|
+
xmlRelaxNGValidityWarningFunc warn,
|
177
|
+
void *ctx);
|
178
|
+
XMLPUBFUN int
|
179
|
+
xmlRelaxNGGetValidErrors(xmlRelaxNGValidCtxtPtr ctxt,
|
180
|
+
xmlRelaxNGValidityErrorFunc *err,
|
181
|
+
xmlRelaxNGValidityWarningFunc *warn,
|
182
|
+
void **ctx);
|
183
|
+
XMLPUBFUN void
|
184
|
+
xmlRelaxNGSetValidStructuredErrors(xmlRelaxNGValidCtxtPtr ctxt,
|
185
|
+
xmlStructuredErrorFunc serror, void *ctx);
|
186
|
+
XMLPUBFUN xmlRelaxNGValidCtxtPtr
|
187
|
+
xmlRelaxNGNewValidCtxt (xmlRelaxNGPtr schema);
|
188
|
+
XMLPUBFUN void
|
189
|
+
xmlRelaxNGFreeValidCtxt (xmlRelaxNGValidCtxtPtr ctxt);
|
190
|
+
XMLPUBFUN int
|
191
|
+
xmlRelaxNGValidateDoc (xmlRelaxNGValidCtxtPtr ctxt,
|
192
|
+
xmlDocPtr doc);
|
193
|
+
/*
|
194
|
+
* Interfaces for progressive validation when possible
|
195
|
+
*/
|
196
|
+
XMLPUBFUN int
|
197
|
+
xmlRelaxNGValidatePushElement (xmlRelaxNGValidCtxtPtr ctxt,
|
198
|
+
xmlDocPtr doc,
|
199
|
+
xmlNodePtr elem);
|
200
|
+
XMLPUBFUN int
|
201
|
+
xmlRelaxNGValidatePushCData (xmlRelaxNGValidCtxtPtr ctxt,
|
202
|
+
const xmlChar *data,
|
203
|
+
int len);
|
204
|
+
XMLPUBFUN int
|
205
|
+
xmlRelaxNGValidatePopElement (xmlRelaxNGValidCtxtPtr ctxt,
|
206
|
+
xmlDocPtr doc,
|
207
|
+
xmlNodePtr elem);
|
208
|
+
XMLPUBFUN int
|
209
|
+
xmlRelaxNGValidateFullElement (xmlRelaxNGValidCtxtPtr ctxt,
|
210
|
+
xmlDocPtr doc,
|
211
|
+
xmlNodePtr elem);
|
212
|
+
|
213
|
+
#ifdef __cplusplus
|
214
|
+
}
|
215
|
+
#endif
|
216
|
+
|
217
|
+
#endif /* LIBXML_SCHEMAS_ENABLED */
|
218
|
+
|
219
|
+
#endif /* __XML_RELAX_NG__ */
|