lxml 6.0.0__cp312-cp312-macosx_10_13_universal2.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (174) hide show
  1. lxml/ElementInclude.py +244 -0
  2. lxml/__init__.py +22 -0
  3. lxml/_elementpath.cpython-312-darwin.so +0 -0
  4. lxml/_elementpath.py +343 -0
  5. lxml/apihelpers.pxi +1801 -0
  6. lxml/builder.cpython-312-darwin.so +0 -0
  7. lxml/builder.py +243 -0
  8. lxml/classlookup.pxi +580 -0
  9. lxml/cleanup.pxi +215 -0
  10. lxml/cssselect.py +101 -0
  11. lxml/debug.pxi +36 -0
  12. lxml/docloader.pxi +178 -0
  13. lxml/doctestcompare.py +488 -0
  14. lxml/dtd.pxi +479 -0
  15. lxml/etree.cpython-312-darwin.so +0 -0
  16. lxml/etree.h +244 -0
  17. lxml/etree.pyx +3853 -0
  18. lxml/etree_api.h +204 -0
  19. lxml/extensions.pxi +830 -0
  20. lxml/html/ElementSoup.py +10 -0
  21. lxml/html/__init__.py +1927 -0
  22. lxml/html/_diffcommand.py +86 -0
  23. lxml/html/_difflib.cpython-312-darwin.so +0 -0
  24. lxml/html/_difflib.py +2106 -0
  25. lxml/html/_html5builder.py +100 -0
  26. lxml/html/_setmixin.py +56 -0
  27. lxml/html/builder.py +173 -0
  28. lxml/html/clean.py +21 -0
  29. lxml/html/defs.py +135 -0
  30. lxml/html/diff.cpython-312-darwin.so +0 -0
  31. lxml/html/diff.py +972 -0
  32. lxml/html/formfill.py +299 -0
  33. lxml/html/html5parser.py +260 -0
  34. lxml/html/soupparser.py +314 -0
  35. lxml/html/usedoctest.py +13 -0
  36. lxml/includes/__init__.pxd +0 -0
  37. lxml/includes/__init__.py +0 -0
  38. lxml/includes/c14n.pxd +25 -0
  39. lxml/includes/config.pxd +3 -0
  40. lxml/includes/dtdvalid.pxd +18 -0
  41. lxml/includes/etree_defs.h +379 -0
  42. lxml/includes/etreepublic.pxd +237 -0
  43. lxml/includes/extlibs/__init__.py +0 -0
  44. lxml/includes/extlibs/libcharset.h +45 -0
  45. lxml/includes/extlibs/localcharset.h +137 -0
  46. lxml/includes/extlibs/zconf.h +543 -0
  47. lxml/includes/extlibs/zlib.h +1938 -0
  48. lxml/includes/htmlparser.pxd +56 -0
  49. lxml/includes/libexslt/__init__.py +0 -0
  50. lxml/includes/libexslt/exslt.h +108 -0
  51. lxml/includes/libexslt/exsltconfig.h +70 -0
  52. lxml/includes/libexslt/exsltexports.h +63 -0
  53. lxml/includes/libxml/HTMLparser.h +339 -0
  54. lxml/includes/libxml/HTMLtree.h +148 -0
  55. lxml/includes/libxml/SAX.h +18 -0
  56. lxml/includes/libxml/SAX2.h +170 -0
  57. lxml/includes/libxml/__init__.py +0 -0
  58. lxml/includes/libxml/c14n.h +115 -0
  59. lxml/includes/libxml/catalog.h +183 -0
  60. lxml/includes/libxml/chvalid.h +230 -0
  61. lxml/includes/libxml/debugXML.h +79 -0
  62. lxml/includes/libxml/dict.h +82 -0
  63. lxml/includes/libxml/encoding.h +307 -0
  64. lxml/includes/libxml/entities.h +147 -0
  65. lxml/includes/libxml/globals.h +25 -0
  66. lxml/includes/libxml/hash.h +251 -0
  67. lxml/includes/libxml/list.h +137 -0
  68. lxml/includes/libxml/nanoftp.h +16 -0
  69. lxml/includes/libxml/nanohttp.h +98 -0
  70. lxml/includes/libxml/parser.h +1633 -0
  71. lxml/includes/libxml/parserInternals.h +591 -0
  72. lxml/includes/libxml/relaxng.h +224 -0
  73. lxml/includes/libxml/schemasInternals.h +959 -0
  74. lxml/includes/libxml/schematron.h +143 -0
  75. lxml/includes/libxml/threads.h +81 -0
  76. lxml/includes/libxml/tree.h +1326 -0
  77. lxml/includes/libxml/uri.h +106 -0
  78. lxml/includes/libxml/valid.h +485 -0
  79. lxml/includes/libxml/xinclude.h +141 -0
  80. lxml/includes/libxml/xlink.h +193 -0
  81. lxml/includes/libxml/xmlIO.h +419 -0
  82. lxml/includes/libxml/xmlautomata.h +163 -0
  83. lxml/includes/libxml/xmlerror.h +962 -0
  84. lxml/includes/libxml/xmlexports.h +96 -0
  85. lxml/includes/libxml/xmlmemory.h +188 -0
  86. lxml/includes/libxml/xmlmodule.h +61 -0
  87. lxml/includes/libxml/xmlreader.h +444 -0
  88. lxml/includes/libxml/xmlregexp.h +116 -0
  89. lxml/includes/libxml/xmlsave.h +111 -0
  90. lxml/includes/libxml/xmlschemas.h +254 -0
  91. lxml/includes/libxml/xmlschemastypes.h +152 -0
  92. lxml/includes/libxml/xmlstring.h +140 -0
  93. lxml/includes/libxml/xmlunicode.h +15 -0
  94. lxml/includes/libxml/xmlversion.h +332 -0
  95. lxml/includes/libxml/xmlwriter.h +489 -0
  96. lxml/includes/libxml/xpath.h +569 -0
  97. lxml/includes/libxml/xpathInternals.h +639 -0
  98. lxml/includes/libxml/xpointer.h +48 -0
  99. lxml/includes/libxslt/__init__.py +0 -0
  100. lxml/includes/libxslt/attributes.h +39 -0
  101. lxml/includes/libxslt/documents.h +93 -0
  102. lxml/includes/libxslt/extensions.h +262 -0
  103. lxml/includes/libxslt/extra.h +72 -0
  104. lxml/includes/libxslt/functions.h +78 -0
  105. lxml/includes/libxslt/imports.h +75 -0
  106. lxml/includes/libxslt/keys.h +53 -0
  107. lxml/includes/libxslt/namespaces.h +68 -0
  108. lxml/includes/libxslt/numbersInternals.h +73 -0
  109. lxml/includes/libxslt/pattern.h +84 -0
  110. lxml/includes/libxslt/preproc.h +43 -0
  111. lxml/includes/libxslt/security.h +104 -0
  112. lxml/includes/libxslt/templates.h +77 -0
  113. lxml/includes/libxslt/transform.h +207 -0
  114. lxml/includes/libxslt/variables.h +118 -0
  115. lxml/includes/libxslt/xslt.h +110 -0
  116. lxml/includes/libxslt/xsltInternals.h +1995 -0
  117. lxml/includes/libxslt/xsltconfig.h +146 -0
  118. lxml/includes/libxslt/xsltexports.h +64 -0
  119. lxml/includes/libxslt/xsltlocale.h +44 -0
  120. lxml/includes/libxslt/xsltutils.h +343 -0
  121. lxml/includes/lxml-version.h +3 -0
  122. lxml/includes/relaxng.pxd +64 -0
  123. lxml/includes/schematron.pxd +34 -0
  124. lxml/includes/tree.pxd +492 -0
  125. lxml/includes/uri.pxd +5 -0
  126. lxml/includes/xinclude.pxd +22 -0
  127. lxml/includes/xmlerror.pxd +852 -0
  128. lxml/includes/xmlparser.pxd +303 -0
  129. lxml/includes/xmlschema.pxd +35 -0
  130. lxml/includes/xpath.pxd +136 -0
  131. lxml/includes/xslt.pxd +190 -0
  132. lxml/isoschematron/__init__.py +348 -0
  133. lxml/isoschematron/resources/rng/iso-schematron.rng +709 -0
  134. lxml/isoschematron/resources/xsl/RNG2Schtrn.xsl +75 -0
  135. lxml/isoschematron/resources/xsl/XSD2Schtrn.xsl +77 -0
  136. lxml/isoschematron/resources/xsl/iso-schematron-xslt1/iso_abstract_expand.xsl +313 -0
  137. lxml/isoschematron/resources/xsl/iso-schematron-xslt1/iso_dsdl_include.xsl +1160 -0
  138. lxml/isoschematron/resources/xsl/iso-schematron-xslt1/iso_schematron_message.xsl +55 -0
  139. lxml/isoschematron/resources/xsl/iso-schematron-xslt1/iso_schematron_skeleton_for_xslt1.xsl +1796 -0
  140. lxml/isoschematron/resources/xsl/iso-schematron-xslt1/iso_svrl_for_xslt1.xsl +588 -0
  141. lxml/isoschematron/resources/xsl/iso-schematron-xslt1/readme.txt +84 -0
  142. lxml/iterparse.pxi +438 -0
  143. lxml/lxml.etree.h +244 -0
  144. lxml/lxml.etree_api.h +204 -0
  145. lxml/nsclasses.pxi +281 -0
  146. lxml/objectify.cpython-312-darwin.so +0 -0
  147. lxml/objectify.pyx +2149 -0
  148. lxml/objectpath.pxi +332 -0
  149. lxml/parser.pxi +2059 -0
  150. lxml/parsertarget.pxi +180 -0
  151. lxml/proxy.pxi +619 -0
  152. lxml/public-api.pxi +178 -0
  153. lxml/pyclasslookup.py +3 -0
  154. lxml/readonlytree.pxi +565 -0
  155. lxml/relaxng.pxi +165 -0
  156. lxml/sax.cpython-312-darwin.so +0 -0
  157. lxml/sax.py +286 -0
  158. lxml/saxparser.pxi +875 -0
  159. lxml/schematron.pxi +173 -0
  160. lxml/serializer.pxi +1849 -0
  161. lxml/usedoctest.py +13 -0
  162. lxml/xinclude.pxi +67 -0
  163. lxml/xmlerror.pxi +1654 -0
  164. lxml/xmlid.pxi +179 -0
  165. lxml/xmlschema.pxi +215 -0
  166. lxml/xpath.pxi +487 -0
  167. lxml/xslt.pxi +957 -0
  168. lxml/xsltext.pxi +242 -0
  169. lxml-6.0.0.dist-info/METADATA +163 -0
  170. lxml-6.0.0.dist-info/RECORD +174 -0
  171. lxml-6.0.0.dist-info/WHEEL +6 -0
  172. lxml-6.0.0.dist-info/licenses/LICENSE.txt +31 -0
  173. lxml-6.0.0.dist-info/licenses/LICENSES.txt +29 -0
  174. lxml-6.0.0.dist-info/top_level.txt +1 -0
@@ -0,0 +1,68 @@
1
+ /*
2
+ * Summary: interface for the XSLT namespace handling
3
+ * Description: set of function easing the processing and generation
4
+ * of namespace nodes in XSLT.
5
+ *
6
+ * Copy: See Copyright for the status of this software.
7
+ *
8
+ * Author: Daniel Veillard
9
+ */
10
+
11
+ #ifndef __XML_XSLT_NAMESPACES_H__
12
+ #define __XML_XSLT_NAMESPACES_H__
13
+
14
+ #include <libxml/tree.h>
15
+ #include "xsltexports.h"
16
+
17
+ #ifdef __cplusplus
18
+ extern "C" {
19
+ #endif
20
+
21
+ /*
22
+ * Used within nsAliases hashtable when the default namespace is required
23
+ * but it's not been explicitly defined
24
+ */
25
+ /**
26
+ * UNDEFINED_DEFAULT_NS:
27
+ *
28
+ * Special value for undefined namespace, internal
29
+ */
30
+ #define UNDEFINED_DEFAULT_NS (const xmlChar *) -1L
31
+
32
+ XSLTPUBFUN void XSLTCALL
33
+ xsltNamespaceAlias (xsltStylesheetPtr style,
34
+ xmlNodePtr node);
35
+ XSLTPUBFUN xmlNsPtr XSLTCALL
36
+ xsltGetNamespace (xsltTransformContextPtr ctxt,
37
+ xmlNodePtr cur,
38
+ xmlNsPtr ns,
39
+ xmlNodePtr out);
40
+ XSLTPUBFUN xmlNsPtr XSLTCALL
41
+ xsltGetPlainNamespace (xsltTransformContextPtr ctxt,
42
+ xmlNodePtr cur,
43
+ xmlNsPtr ns,
44
+ xmlNodePtr out);
45
+ XSLTPUBFUN xmlNsPtr XSLTCALL
46
+ xsltGetSpecialNamespace (xsltTransformContextPtr ctxt,
47
+ xmlNodePtr cur,
48
+ const xmlChar *URI,
49
+ const xmlChar *prefix,
50
+ xmlNodePtr out);
51
+ XSLTPUBFUN xmlNsPtr XSLTCALL
52
+ xsltCopyNamespace (xsltTransformContextPtr ctxt,
53
+ xmlNodePtr elem,
54
+ xmlNsPtr ns);
55
+ XSLTPUBFUN xmlNsPtr XSLTCALL
56
+ xsltCopyNamespaceList (xsltTransformContextPtr ctxt,
57
+ xmlNodePtr node,
58
+ xmlNsPtr cur);
59
+ XSLTPUBFUN void XSLTCALL
60
+ xsltFreeNamespaceAliasHashes
61
+ (xsltStylesheetPtr style);
62
+
63
+ #ifdef __cplusplus
64
+ }
65
+ #endif
66
+
67
+ #endif /* __XML_XSLT_NAMESPACES_H__ */
68
+
@@ -0,0 +1,73 @@
1
+ /*
2
+ * Summary: Implementation of the XSLT number functions
3
+ * Description: Implementation of the XSLT number functions
4
+ *
5
+ * Copy: See Copyright for the status of this software.
6
+ *
7
+ * Author: Bjorn Reese <breese@users.sourceforge.net> and Daniel Veillard
8
+ */
9
+
10
+ #ifndef __XML_XSLT_NUMBERSINTERNALS_H__
11
+ #define __XML_XSLT_NUMBERSINTERNALS_H__
12
+
13
+ #include <libxml/tree.h>
14
+ #include "xsltexports.h"
15
+
16
+ #ifdef __cplusplus
17
+ extern "C" {
18
+ #endif
19
+
20
+ struct _xsltCompMatch;
21
+
22
+ /**
23
+ * xsltNumberData:
24
+ *
25
+ * This data structure is just a wrapper to pass xsl:number data in.
26
+ */
27
+ typedef struct _xsltNumberData xsltNumberData;
28
+ typedef xsltNumberData *xsltNumberDataPtr;
29
+
30
+ struct _xsltNumberData {
31
+ const xmlChar *level;
32
+ const xmlChar *count;
33
+ const xmlChar *from;
34
+ const xmlChar *value;
35
+ const xmlChar *format;
36
+ int has_format;
37
+ int digitsPerGroup;
38
+ int groupingCharacter;
39
+ int groupingCharacterLen;
40
+ xmlDocPtr doc;
41
+ xmlNodePtr node;
42
+ struct _xsltCompMatch *countPat;
43
+ struct _xsltCompMatch *fromPat;
44
+
45
+ /*
46
+ * accelerators
47
+ */
48
+ };
49
+
50
+ /**
51
+ * xsltFormatNumberInfo,:
52
+ *
53
+ * This data structure lists the various parameters needed to format numbers.
54
+ */
55
+ typedef struct _xsltFormatNumberInfo xsltFormatNumberInfo;
56
+ typedef xsltFormatNumberInfo *xsltFormatNumberInfoPtr;
57
+
58
+ struct _xsltFormatNumberInfo {
59
+ int integer_hash; /* Number of '#' in integer part */
60
+ int integer_digits; /* Number of '0' in integer part */
61
+ int frac_digits; /* Number of '0' in fractional part */
62
+ int frac_hash; /* Number of '#' in fractional part */
63
+ int group; /* Number of chars per display 'group' */
64
+ int multiplier; /* Scaling for percent or permille */
65
+ char add_decimal; /* Flag for whether decimal point appears in pattern */
66
+ char is_multiplier_set; /* Flag to catch multiple occurences of percent/permille */
67
+ char is_negative_pattern;/* Flag for processing -ve prefix/suffix */
68
+ };
69
+
70
+ #ifdef __cplusplus
71
+ }
72
+ #endif
73
+ #endif /* __XML_XSLT_NUMBERSINTERNALS_H__ */
@@ -0,0 +1,84 @@
1
+ /*
2
+ * Summary: interface for the pattern matching used in template matches.
3
+ * Description: the implementation of the lookup of the right template
4
+ * for a given node must be really fast in order to keep
5
+ * decent performances.
6
+ *
7
+ * Copy: See Copyright for the status of this software.
8
+ *
9
+ * Author: Daniel Veillard
10
+ */
11
+
12
+ #ifndef __XML_XSLT_PATTERN_H__
13
+ #define __XML_XSLT_PATTERN_H__
14
+
15
+ #include "xsltInternals.h"
16
+ #include "xsltexports.h"
17
+
18
+ #ifdef __cplusplus
19
+ extern "C" {
20
+ #endif
21
+
22
+ /**
23
+ * xsltCompMatch:
24
+ *
25
+ * Data structure used for the implementation of patterns.
26
+ * It is kept private (in pattern.c).
27
+ */
28
+ typedef struct _xsltCompMatch xsltCompMatch;
29
+ typedef xsltCompMatch *xsltCompMatchPtr;
30
+
31
+ /*
32
+ * Pattern related interfaces.
33
+ */
34
+
35
+ XSLTPUBFUN xsltCompMatchPtr XSLTCALL
36
+ xsltCompilePattern (const xmlChar *pattern,
37
+ xmlDocPtr doc,
38
+ xmlNodePtr node,
39
+ xsltStylesheetPtr style,
40
+ xsltTransformContextPtr runtime);
41
+ XSLTPUBFUN void XSLTCALL
42
+ xsltFreeCompMatchList (xsltCompMatchPtr comp);
43
+ XSLTPUBFUN int XSLTCALL
44
+ xsltTestCompMatchList (xsltTransformContextPtr ctxt,
45
+ xmlNodePtr node,
46
+ xsltCompMatchPtr comp);
47
+ XSLTPUBFUN void XSLTCALL
48
+ xsltCompMatchClearCache (xsltTransformContextPtr ctxt,
49
+ xsltCompMatchPtr comp);
50
+ XSLTPUBFUN void XSLTCALL
51
+ xsltNormalizeCompSteps (void *payload,
52
+ void *data,
53
+ const xmlChar *name);
54
+
55
+ /*
56
+ * Template related interfaces.
57
+ */
58
+ XSLTPUBFUN int XSLTCALL
59
+ xsltAddTemplate (xsltStylesheetPtr style,
60
+ xsltTemplatePtr cur,
61
+ const xmlChar *mode,
62
+ const xmlChar *modeURI);
63
+ XSLTPUBFUN xsltTemplatePtr XSLTCALL
64
+ xsltGetTemplate (xsltTransformContextPtr ctxt,
65
+ xmlNodePtr node,
66
+ xsltStylesheetPtr style);
67
+ XSLTPUBFUN void XSLTCALL
68
+ xsltFreeTemplateHashes (xsltStylesheetPtr style);
69
+ XSLTPUBFUN void XSLTCALL
70
+ xsltCleanupTemplates (xsltStylesheetPtr style);
71
+
72
+ #if 0
73
+ int xsltMatchPattern (xsltTransformContextPtr ctxt,
74
+ xmlNodePtr node,
75
+ const xmlChar *pattern,
76
+ xmlDocPtr ctxtdoc,
77
+ xmlNodePtr ctxtnode);
78
+ #endif
79
+ #ifdef __cplusplus
80
+ }
81
+ #endif
82
+
83
+ #endif /* __XML_XSLT_PATTERN_H__ */
84
+
@@ -0,0 +1,43 @@
1
+ /*
2
+ * Summary: precomputing stylesheets
3
+ * Description: this is the compilation phase, where most of the
4
+ * stylesheet is "compiled" into faster to use data.
5
+ *
6
+ * Copy: See Copyright for the status of this software.
7
+ *
8
+ * Author: Daniel Veillard
9
+ */
10
+
11
+ #ifndef __XML_XSLT_PRECOMP_H__
12
+ #define __XML_XSLT_PRECOMP_H__
13
+
14
+ #include <libxml/tree.h>
15
+ #include "xsltexports.h"
16
+ #include "xsltInternals.h"
17
+
18
+ #ifdef __cplusplus
19
+ extern "C" {
20
+ #endif
21
+
22
+ /*
23
+ * Interfaces
24
+ */
25
+ XSLTPUBVAR const xmlChar *xsltExtMarker;
26
+
27
+ XSLTPUBFUN xsltElemPreCompPtr XSLTCALL
28
+ xsltDocumentComp (xsltStylesheetPtr style,
29
+ xmlNodePtr inst,
30
+ xsltTransformFunction function);
31
+
32
+ XSLTPUBFUN void XSLTCALL
33
+ xsltStylePreCompute (xsltStylesheetPtr style,
34
+ xmlNodePtr inst);
35
+ XSLTPUBFUN void XSLTCALL
36
+ xsltFreeStylePreComps (xsltStylesheetPtr style);
37
+
38
+ #ifdef __cplusplus
39
+ }
40
+ #endif
41
+
42
+ #endif /* __XML_XSLT_PRECOMP_H__ */
43
+
@@ -0,0 +1,104 @@
1
+ /*
2
+ * Summary: interface for the libxslt security framework
3
+ * Description: the libxslt security framework allow to restrict
4
+ * the access to new resources (file or URL) from
5
+ * the stylesheet at runtime.
6
+ *
7
+ * Copy: See Copyright for the status of this software.
8
+ *
9
+ * Author: Daniel Veillard
10
+ */
11
+
12
+ #ifndef __XML_XSLT_SECURITY_H__
13
+ #define __XML_XSLT_SECURITY_H__
14
+
15
+ #include <libxml/tree.h>
16
+ #include "xsltexports.h"
17
+ #include "xsltInternals.h"
18
+
19
+ #ifdef __cplusplus
20
+ extern "C" {
21
+ #endif
22
+
23
+ /**
24
+ * xsltSecurityPref:
25
+ *
26
+ * structure to indicate the preferences for security in the XSLT
27
+ * transformation.
28
+ */
29
+ typedef struct _xsltSecurityPrefs xsltSecurityPrefs;
30
+ typedef xsltSecurityPrefs *xsltSecurityPrefsPtr;
31
+
32
+ /**
33
+ * xsltSecurityOption:
34
+ *
35
+ * the set of option that can be configured
36
+ */
37
+ typedef enum {
38
+ XSLT_SECPREF_READ_FILE = 1,
39
+ XSLT_SECPREF_WRITE_FILE,
40
+ XSLT_SECPREF_CREATE_DIRECTORY,
41
+ XSLT_SECPREF_READ_NETWORK,
42
+ XSLT_SECPREF_WRITE_NETWORK
43
+ } xsltSecurityOption;
44
+
45
+ /**
46
+ * xsltSecurityCheck:
47
+ *
48
+ * User provided function to check the value of a string like a file
49
+ * path or an URL ...
50
+ */
51
+ typedef int (*xsltSecurityCheck) (xsltSecurityPrefsPtr sec,
52
+ xsltTransformContextPtr ctxt,
53
+ const char *value);
54
+
55
+ /*
56
+ * Module interfaces
57
+ */
58
+ XSLTPUBFUN xsltSecurityPrefsPtr XSLTCALL
59
+ xsltNewSecurityPrefs (void);
60
+ XSLTPUBFUN void XSLTCALL
61
+ xsltFreeSecurityPrefs (xsltSecurityPrefsPtr sec);
62
+ XSLTPUBFUN int XSLTCALL
63
+ xsltSetSecurityPrefs (xsltSecurityPrefsPtr sec,
64
+ xsltSecurityOption option,
65
+ xsltSecurityCheck func);
66
+ XSLTPUBFUN xsltSecurityCheck XSLTCALL
67
+ xsltGetSecurityPrefs (xsltSecurityPrefsPtr sec,
68
+ xsltSecurityOption option);
69
+
70
+ XSLTPUBFUN void XSLTCALL
71
+ xsltSetDefaultSecurityPrefs (xsltSecurityPrefsPtr sec);
72
+ XSLTPUBFUN xsltSecurityPrefsPtr XSLTCALL
73
+ xsltGetDefaultSecurityPrefs (void);
74
+
75
+ XSLTPUBFUN int XSLTCALL
76
+ xsltSetCtxtSecurityPrefs (xsltSecurityPrefsPtr sec,
77
+ xsltTransformContextPtr ctxt);
78
+
79
+ XSLTPUBFUN int XSLTCALL
80
+ xsltSecurityAllow (xsltSecurityPrefsPtr sec,
81
+ xsltTransformContextPtr ctxt,
82
+ const char *value);
83
+ XSLTPUBFUN int XSLTCALL
84
+ xsltSecurityForbid (xsltSecurityPrefsPtr sec,
85
+ xsltTransformContextPtr ctxt,
86
+ const char *value);
87
+ /*
88
+ * internal interfaces
89
+ */
90
+ XSLTPUBFUN int XSLTCALL
91
+ xsltCheckWrite (xsltSecurityPrefsPtr sec,
92
+ xsltTransformContextPtr ctxt,
93
+ const xmlChar *URL);
94
+ XSLTPUBFUN int XSLTCALL
95
+ xsltCheckRead (xsltSecurityPrefsPtr sec,
96
+ xsltTransformContextPtr ctxt,
97
+ const xmlChar *URL);
98
+
99
+ #ifdef __cplusplus
100
+ }
101
+ #endif
102
+
103
+ #endif /* __XML_XSLT_SECURITY_H__ */
104
+
@@ -0,0 +1,77 @@
1
+ /*
2
+ * Summary: interface for the template processing
3
+ * Description: This set of routine encapsulates XPath calls
4
+ * and Attribute Value Templates evaluation.
5
+ *
6
+ * Copy: See Copyright for the status of this software.
7
+ *
8
+ * Author: Daniel Veillard
9
+ */
10
+
11
+ #ifndef __XML_XSLT_TEMPLATES_H__
12
+ #define __XML_XSLT_TEMPLATES_H__
13
+
14
+ #include <libxml/xpath.h>
15
+ #include <libxml/xpathInternals.h>
16
+ #include "xsltexports.h"
17
+ #include "xsltInternals.h"
18
+
19
+ #ifdef __cplusplus
20
+ extern "C" {
21
+ #endif
22
+
23
+ XSLTPUBFUN int XSLTCALL
24
+ xsltEvalXPathPredicate (xsltTransformContextPtr ctxt,
25
+ xmlXPathCompExprPtr comp,
26
+ xmlNsPtr *nsList,
27
+ int nsNr);
28
+ XSLTPUBFUN xmlChar * XSLTCALL
29
+ xsltEvalTemplateString (xsltTransformContextPtr ctxt,
30
+ xmlNodePtr contextNode,
31
+ xmlNodePtr inst);
32
+ XSLTPUBFUN xmlChar * XSLTCALL
33
+ xsltEvalAttrValueTemplate (xsltTransformContextPtr ctxt,
34
+ xmlNodePtr node,
35
+ const xmlChar *name,
36
+ const xmlChar *ns);
37
+ XSLTPUBFUN const xmlChar * XSLTCALL
38
+ xsltEvalStaticAttrValueTemplate (xsltStylesheetPtr style,
39
+ xmlNodePtr node,
40
+ const xmlChar *name,
41
+ const xmlChar *ns,
42
+ int *found);
43
+
44
+ /* TODO: this is obviously broken ... the namespaces should be passed too ! */
45
+ XSLTPUBFUN xmlChar * XSLTCALL
46
+ xsltEvalXPathString (xsltTransformContextPtr ctxt,
47
+ xmlXPathCompExprPtr comp);
48
+ XSLTPUBFUN xmlChar * XSLTCALL
49
+ xsltEvalXPathStringNs (xsltTransformContextPtr ctxt,
50
+ xmlXPathCompExprPtr comp,
51
+ int nsNr,
52
+ xmlNsPtr *nsList);
53
+
54
+ XSLTPUBFUN xmlNodePtr * XSLTCALL
55
+ xsltTemplateProcess (xsltTransformContextPtr ctxt,
56
+ xmlNodePtr node);
57
+ XSLTPUBFUN xmlAttrPtr XSLTCALL
58
+ xsltAttrListTemplateProcess (xsltTransformContextPtr ctxt,
59
+ xmlNodePtr target,
60
+ xmlAttrPtr cur);
61
+ XSLTPUBFUN xmlAttrPtr XSLTCALL
62
+ xsltAttrTemplateProcess (xsltTransformContextPtr ctxt,
63
+ xmlNodePtr target,
64
+ xmlAttrPtr attr);
65
+ XSLTPUBFUN xmlChar * XSLTCALL
66
+ xsltAttrTemplateValueProcess (xsltTransformContextPtr ctxt,
67
+ const xmlChar* attr);
68
+ XSLTPUBFUN xmlChar * XSLTCALL
69
+ xsltAttrTemplateValueProcessNode(xsltTransformContextPtr ctxt,
70
+ const xmlChar* str,
71
+ xmlNodePtr node);
72
+ #ifdef __cplusplus
73
+ }
74
+ #endif
75
+
76
+ #endif /* __XML_XSLT_TEMPLATES_H__ */
77
+
@@ -0,0 +1,207 @@
1
+ /*
2
+ * Summary: the XSLT engine transformation part.
3
+ * Description: This module implements the bulk of the actual
4
+ * transformation processing. Most of the xsl: element
5
+ * constructs are implemented in this module.
6
+ *
7
+ * Copy: See Copyright for the status of this software.
8
+ *
9
+ * Author: Daniel Veillard
10
+ */
11
+
12
+ #ifndef __XML_XSLT_TRANSFORM_H__
13
+ #define __XML_XSLT_TRANSFORM_H__
14
+
15
+ #include <libxml/parser.h>
16
+ #include <libxml/xmlIO.h>
17
+ #include "xsltexports.h"
18
+ #include <libxslt/xsltInternals.h>
19
+
20
+ #ifdef __cplusplus
21
+ extern "C" {
22
+ #endif
23
+
24
+ /**
25
+ * XInclude default processing.
26
+ */
27
+ XSLTPUBFUN void XSLTCALL
28
+ xsltSetXIncludeDefault (int xinclude);
29
+ XSLTPUBFUN int XSLTCALL
30
+ xsltGetXIncludeDefault (void);
31
+
32
+ /**
33
+ * Export context to users.
34
+ */
35
+ XSLTPUBFUN xsltTransformContextPtr XSLTCALL
36
+ xsltNewTransformContext (xsltStylesheetPtr style,
37
+ xmlDocPtr doc);
38
+
39
+ XSLTPUBFUN void XSLTCALL
40
+ xsltFreeTransformContext(xsltTransformContextPtr ctxt);
41
+
42
+ XSLTPUBFUN xmlDocPtr XSLTCALL
43
+ xsltApplyStylesheetUser (xsltStylesheetPtr style,
44
+ xmlDocPtr doc,
45
+ const char **params,
46
+ const char *output,
47
+ FILE * profile,
48
+ xsltTransformContextPtr userCtxt);
49
+ XSLTPUBFUN void XSLTCALL
50
+ xsltProcessOneNode (xsltTransformContextPtr ctxt,
51
+ xmlNodePtr node,
52
+ xsltStackElemPtr params);
53
+ /**
54
+ * Private Interfaces.
55
+ */
56
+ XSLTPUBFUN void XSLTCALL
57
+ xsltApplyStripSpaces (xsltTransformContextPtr ctxt,
58
+ xmlNodePtr node);
59
+ XSLTPUBFUN xmlDocPtr XSLTCALL
60
+ xsltApplyStylesheet (xsltStylesheetPtr style,
61
+ xmlDocPtr doc,
62
+ const char **params);
63
+ XSLTPUBFUN xmlDocPtr XSLTCALL
64
+ xsltProfileStylesheet (xsltStylesheetPtr style,
65
+ xmlDocPtr doc,
66
+ const char **params,
67
+ FILE * output);
68
+ XSLTPUBFUN int XSLTCALL
69
+ xsltRunStylesheet (xsltStylesheetPtr style,
70
+ xmlDocPtr doc,
71
+ const char **params,
72
+ const char *output,
73
+ xmlSAXHandlerPtr SAX,
74
+ xmlOutputBufferPtr IObuf);
75
+ XSLTPUBFUN int XSLTCALL
76
+ xsltRunStylesheetUser (xsltStylesheetPtr style,
77
+ xmlDocPtr doc,
78
+ const char **params,
79
+ const char *output,
80
+ xmlSAXHandlerPtr SAX,
81
+ xmlOutputBufferPtr IObuf,
82
+ FILE * profile,
83
+ xsltTransformContextPtr userCtxt);
84
+ XSLTPUBFUN void XSLTCALL
85
+ xsltApplyOneTemplate (xsltTransformContextPtr ctxt,
86
+ xmlNodePtr node,
87
+ xmlNodePtr list,
88
+ xsltTemplatePtr templ,
89
+ xsltStackElemPtr params);
90
+ XSLTPUBFUN void XSLTCALL
91
+ xsltDocumentElem (xsltTransformContextPtr ctxt,
92
+ xmlNodePtr node,
93
+ xmlNodePtr inst,
94
+ xsltElemPreCompPtr comp);
95
+ XSLTPUBFUN void XSLTCALL
96
+ xsltSort (xsltTransformContextPtr ctxt,
97
+ xmlNodePtr node,
98
+ xmlNodePtr inst,
99
+ xsltElemPreCompPtr comp);
100
+ XSLTPUBFUN void XSLTCALL
101
+ xsltCopy (xsltTransformContextPtr ctxt,
102
+ xmlNodePtr node,
103
+ xmlNodePtr inst,
104
+ xsltElemPreCompPtr comp);
105
+ XSLTPUBFUN void XSLTCALL
106
+ xsltText (xsltTransformContextPtr ctxt,
107
+ xmlNodePtr node,
108
+ xmlNodePtr inst,
109
+ xsltElemPreCompPtr comp);
110
+ XSLTPUBFUN void XSLTCALL
111
+ xsltElement (xsltTransformContextPtr ctxt,
112
+ xmlNodePtr node,
113
+ xmlNodePtr inst,
114
+ xsltElemPreCompPtr comp);
115
+ XSLTPUBFUN void XSLTCALL
116
+ xsltComment (xsltTransformContextPtr ctxt,
117
+ xmlNodePtr node,
118
+ xmlNodePtr inst,
119
+ xsltElemPreCompPtr comp);
120
+ XSLTPUBFUN void XSLTCALL
121
+ xsltAttribute (xsltTransformContextPtr ctxt,
122
+ xmlNodePtr node,
123
+ xmlNodePtr inst,
124
+ xsltElemPreCompPtr comp);
125
+ XSLTPUBFUN void XSLTCALL
126
+ xsltProcessingInstruction(xsltTransformContextPtr ctxt,
127
+ xmlNodePtr node,
128
+ xmlNodePtr inst,
129
+ xsltElemPreCompPtr comp);
130
+ XSLTPUBFUN void XSLTCALL
131
+ xsltCopyOf (xsltTransformContextPtr ctxt,
132
+ xmlNodePtr node,
133
+ xmlNodePtr inst,
134
+ xsltElemPreCompPtr comp);
135
+ XSLTPUBFUN void XSLTCALL
136
+ xsltValueOf (xsltTransformContextPtr ctxt,
137
+ xmlNodePtr node,
138
+ xmlNodePtr inst,
139
+ xsltElemPreCompPtr comp);
140
+ XSLTPUBFUN void XSLTCALL
141
+ xsltNumber (xsltTransformContextPtr ctxt,
142
+ xmlNodePtr node,
143
+ xmlNodePtr inst,
144
+ xsltElemPreCompPtr comp);
145
+ XSLTPUBFUN void XSLTCALL
146
+ xsltApplyImports (xsltTransformContextPtr ctxt,
147
+ xmlNodePtr node,
148
+ xmlNodePtr inst,
149
+ xsltElemPreCompPtr comp);
150
+ XSLTPUBFUN void XSLTCALL
151
+ xsltCallTemplate (xsltTransformContextPtr ctxt,
152
+ xmlNodePtr node,
153
+ xmlNodePtr inst,
154
+ xsltElemPreCompPtr comp);
155
+ XSLTPUBFUN void XSLTCALL
156
+ xsltApplyTemplates (xsltTransformContextPtr ctxt,
157
+ xmlNodePtr node,
158
+ xmlNodePtr inst,
159
+ xsltElemPreCompPtr comp);
160
+ XSLTPUBFUN void XSLTCALL
161
+ xsltChoose (xsltTransformContextPtr ctxt,
162
+ xmlNodePtr node,
163
+ xmlNodePtr inst,
164
+ xsltElemPreCompPtr comp);
165
+ XSLTPUBFUN void XSLTCALL
166
+ xsltIf (xsltTransformContextPtr ctxt,
167
+ xmlNodePtr node,
168
+ xmlNodePtr inst,
169
+ xsltElemPreCompPtr comp);
170
+ XSLTPUBFUN void XSLTCALL
171
+ xsltForEach (xsltTransformContextPtr ctxt,
172
+ xmlNodePtr node,
173
+ xmlNodePtr inst,
174
+ xsltElemPreCompPtr comp);
175
+ XSLTPUBFUN void XSLTCALL
176
+ xsltRegisterAllElement (xsltTransformContextPtr ctxt);
177
+
178
+ XSLTPUBFUN xmlNodePtr XSLTCALL
179
+ xsltCopyTextString (xsltTransformContextPtr ctxt,
180
+ xmlNodePtr target,
181
+ const xmlChar *string,
182
+ int noescape);
183
+
184
+ /* Following 2 functions needed for libexslt/functions.c */
185
+ XSLTPUBFUN void XSLTCALL
186
+ xsltLocalVariablePop (xsltTransformContextPtr ctxt,
187
+ int limitNr,
188
+ int level);
189
+ XSLTPUBFUN int XSLTCALL
190
+ xsltLocalVariablePush (xsltTransformContextPtr ctxt,
191
+ xsltStackElemPtr variable,
192
+ int level);
193
+ /*
194
+ * Hook for the debugger if activated.
195
+ */
196
+ XSLTPUBFUN void XSLTCALL
197
+ xslHandleDebugger (xmlNodePtr cur,
198
+ xmlNodePtr node,
199
+ xsltTemplatePtr templ,
200
+ xsltTransformContextPtr ctxt);
201
+
202
+ #ifdef __cplusplus
203
+ }
204
+ #endif
205
+
206
+ #endif /* __XML_XSLT_TRANSFORM_H__ */
207
+