ReactOS 0.4.16-dev-2132-g3885311
parser.h
Go to the documentation of this file.
1/*
2 * Summary: the core parser module
3 * Description: Interfaces, constants and types related to the XML parser
4 *
5 * Copy: See Copyright for the status of this software.
6 *
7 * Author: Daniel Veillard
8 */
9
10#ifndef __XML_PARSER_H__
11#define __XML_PARSER_H__
12
13#include <libxml/xmlversion.h>
14#define XML_TREE_INTERNALS
15#include <libxml/tree.h>
16#undef XML_TREE_INTERNALS
17#include <libxml/dict.h>
18#include <libxml/hash.h>
19#include <libxml/valid.h>
20#include <libxml/entities.h>
21#include <libxml/xmlerror.h>
22#include <libxml/xmlstring.h>
23#include <libxml/xmlmemory.h>
24#include <libxml/encoding.h>
25#include <libxml/xmlIO.h>
26/* for compatibility */
27#include <libxml/SAX2.h>
28#include <libxml/threads.h>
29
30#ifdef __cplusplus
31extern "C" {
32#endif
33
39#define XML_DEFAULT_VERSION "1.0"
40
59
61 /* Input buffer */
62 xmlParserInputBufferPtr buf; /* UTF-8 encoded buffer */
63
64 const char *filename; /* The file analyzed, if any */
65 const char *directory; /* the directory/base of the file */
66 const xmlChar *base; /* Base of the array to parse */
67 const xmlChar *cur; /* Current char being parsed */
68 const xmlChar *end; /* end of the array to parse */
69 int length; /* length if known */
70 int line; /* Current line */
71 int col; /* Current column */
72 unsigned long consumed; /* How many xmlChars already consumed */
73 xmlParserInputDeallocate free; /* function to deallocate the base */
74 const xmlChar *encoding; /* unused */
75 const xmlChar *version; /* the version string for entity */
76 int flags; /* Flags */
77 int id; /* an unique identifier for the entity */
78 unsigned long parentConsumed; /* consumed bytes from parents */
79 xmlEntityPtr entity; /* entity, if any */
80};
81
91
93 const struct _xmlNode* node;
94 /* Position & line # that text that created the node begins & ends on */
95 unsigned long begin_pos;
96 unsigned long begin_line;
97 unsigned long end_pos;
98 unsigned long end_line;
99};
100
104 unsigned long maximum;
105 unsigned long length;
107};
108
115typedef enum {
116 XML_PARSER_EOF = -1, /* nothing is to be parsed */
117 XML_PARSER_START = 0, /* nothing has been parsed */
118 XML_PARSER_MISC, /* Misc* before int subset */
119 XML_PARSER_PI, /* Within a processing instruction */
120 XML_PARSER_DTD, /* within some DTD content */
121 XML_PARSER_PROLOG, /* Misc* after internal subset */
122 XML_PARSER_COMMENT, /* within a comment */
123 XML_PARSER_START_TAG, /* within a start tag */
124 XML_PARSER_CONTENT, /* within the content */
125 XML_PARSER_CDATA_SECTION, /* within a CDATA section */
126 XML_PARSER_END_TAG, /* within a closing tag */
127 XML_PARSER_ENTITY_DECL, /* within an entity declaration */
128 XML_PARSER_ENTITY_VALUE, /* within an entity value in a decl */
129 XML_PARSER_ATTRIBUTE_VALUE, /* within an attribute value */
130 XML_PARSER_SYSTEM_LITERAL, /* within a SYSTEM value */
131 XML_PARSER_EPILOG, /* the Misc* after the last end tag */
132 XML_PARSER_IGNORE, /* within an IGNORED section */
133 XML_PARSER_PUBLIC_LITERAL, /* within a PUBLIC value */
134 XML_PARSER_XML_DECL /* before XML decl (but after BOM) */
136
143#define XML_DETECT_IDS 2
144
152#define XML_COMPLETE_ATTRS 4
153
160#define XML_SKIP_IDS 8
161
167typedef enum {
175
179
193 struct _xmlSAXHandler *sax; /* The SAX handler */
194 void *userData; /* For SAX interface only, used by DOM build */
195 xmlDocPtr myDoc; /* the document being built */
196 int wellFormed; /* is the document well formed */
197 int replaceEntities; /* shall we replace entities ? */
198 const xmlChar *version; /* the XML version string */
199 const xmlChar *encoding; /* the declared encoding, if any */
200 int standalone; /* standalone document */
201 int html; /* an HTML(1) document
202 * 3 is HTML after <head>
203 * 10 is HTML after <body>
204 */
205
206 /* Input stream stack */
207 xmlParserInputPtr input; /* Current input stream */
208 int inputNr; /* Number of current input streams */
209 int inputMax; /* Max number of input streams */
210 xmlParserInputPtr *inputTab; /* stack of inputs */
211
212 /* Node analysis stack only used for DOM building */
213 xmlNodePtr node; /* Current parsed Node */
214 int nodeNr; /* Depth of the parsing stack */
215 int nodeMax; /* Max depth of the parsing stack */
216 xmlNodePtr *nodeTab; /* array of nodes */
217
218 int record_info; /* Whether node info should be kept */
219 xmlParserNodeInfoSeq node_seq; /* info about each node parsed */
220
221 int errNo; /* error code */
222
223 int hasExternalSubset; /* reference and external subset */
224 int hasPErefs; /* the internal subset has PE refs */
225 int external; /* are we parsing an external entity */
226
227 int valid; /* is the document valid */
228 int validate; /* shall we try to validate ? */
229 xmlValidCtxt vctxt; /* The validity context */
230
231 xmlParserInputState instate; /* current type of input */
232 int token; /* next char look-ahead */
233
234 char *directory; /* the data directory */
235
236 /* Node name stack */
237 const xmlChar *name; /* Current parsed Node */
238 int nameNr; /* Depth of the parsing stack */
239 int nameMax; /* Max depth of the parsing stack */
240 const xmlChar * *nameTab; /* array of nodes */
241
242 long nbChars; /* unused */
243 long checkIndex; /* used by progressive parsing lookup */
244 int keepBlanks; /* ugly but ... */
245 int disableSAX; /* SAX callbacks are disabled */
246 int inSubset; /* Parsing is in int 1/ext 2 subset */
247 const xmlChar * intSubName; /* name of subset */
248 xmlChar * extSubURI; /* URI of external subset */
249 xmlChar * extSubSystem; /* SYSTEM ID of external subset */
250
251 /* xml:space values */
252 int * space; /* Should the parser preserve spaces */
253 int spaceNr; /* Depth of the parsing stack */
254 int spaceMax; /* Max depth of the parsing stack */
255 int * spaceTab; /* array of space infos */
256
257 int depth; /* to prevent entity substitution loops */
258 xmlParserInputPtr entity; /* used to check entities boundaries */
259 int charset; /* unused */
260 int nodelen; /* Those two fields are there to */
261 int nodemem; /* Speed up large node parsing */
262 int pedantic; /* signal pedantic warnings */
263 void *_private; /* For user data, libxml won't touch it */
264
265 int loadsubset; /* should the external subset be loaded */
266 int linenumbers; /* set line number in element content */
267 void *catalogs; /* document's own catalog */
268 int recovery; /* run in recovery mode */
269 int progressive; /* is this a progressive parsing */
270 xmlDictPtr dict; /* dictionary for the parser */
271 const xmlChar * *atts; /* array for the attributes callbacks */
272 int maxatts; /* the size of the array */
273 int docdict; /* use strings from dict to build tree */
274
275 /*
276 * pre-interned strings
277 */
281
282 /*
283 * Everything below is used only by the new SAX mode
284 */
285 int sax2; /* operating in the new SAX mode */
286 int nsNr; /* the number of inherited namespaces */
287 int nsMax; /* the size of the arrays */
288 const xmlChar * *nsTab; /* the array of prefix/namespace name */
289 unsigned *attallocs; /* which attribute were allocated */
290 xmlStartTag *pushTab; /* array of data for push */
291 xmlHashTablePtr attsDefault; /* defaulted attributes if any */
292 xmlHashTablePtr attsSpecial; /* non-CDATA attributes if any */
293 int nsWellFormed; /* is the document XML Namespace okay */
294 int options; /* Extra options */
295
296 /*
297 * Those fields are needed only for streaming parsing so far
298 */
299 int dictNames; /* Use dictionary names for the tree */
300 int freeElemsNr; /* number of freed element nodes */
301 xmlNodePtr freeElems; /* List of freed element nodes */
302 int freeAttrsNr; /* number of freed attributes nodes */
303 xmlAttrPtr freeAttrs; /* List of freed attributes nodes */
304
305 /*
306 * the complete error information for the last error.
307 */
309 xmlParserMode parseMode; /* the parser mode */
310 unsigned long nbentities; /* unused */
311 unsigned long sizeentities; /* size of parsed entities */
312
313 /* for use by HTML non-recursive parser */
314 xmlParserNodeInfo *nodeInfo; /* Current NodeInfo */
315 int nodeInfoNr; /* Depth of the parsing stack */
316 int nodeInfoMax; /* Max depth of the parsing stack */
317 xmlParserNodeInfo *nodeInfoTab; /* array of nodeInfos */
318
319 int input_id; /* we need to label inputs */
320 unsigned long sizeentcopy; /* volume of entity copy */
321
322 int endCheckState; /* quote state for push parser */
323 unsigned short nbErrors; /* number of errors */
324 unsigned short nbWarnings; /* number of warnings */
325 unsigned maxAmpl; /* maximum amplification factor */
326
327 xmlParserNsData *nsdb; /* namespace database */
328 unsigned attrHashMax; /* allocated size */
329 xmlAttrHashBucket *attrHash; /* atttribute hash table */
330};
331
338 const xmlChar *(*getPublicId)(void *ctx);
339 const xmlChar *(*getSystemId)(void *ctx);
342};
343
366typedef xmlParserInputPtr (*resolveEntitySAXFunc) (void *ctx,
367 const xmlChar *publicId,
368 const xmlChar *systemId);
379 const xmlChar *name,
380 const xmlChar *ExternalID,
381 const xmlChar *SystemID);
392 const xmlChar *name,
393 const xmlChar *ExternalID,
394 const xmlChar *SystemID);
404typedef xmlEntityPtr (*getEntitySAXFunc) (void *ctx,
405 const xmlChar *name);
415typedef xmlEntityPtr (*getParameterEntitySAXFunc) (void *ctx,
416 const xmlChar *name);
428typedef void (*entityDeclSAXFunc) (void *ctx,
429 const xmlChar *name,
430 int type,
431 const xmlChar *publicId,
432 const xmlChar *systemId,
443typedef void (*notationDeclSAXFunc)(void *ctx,
444 const xmlChar *name,
445 const xmlChar *publicId,
446 const xmlChar *systemId);
460 const xmlChar *elem,
461 const xmlChar *fullname,
462 int type,
463 int def,
464 const xmlChar *defaultValue,
465 xmlEnumerationPtr tree);
475typedef void (*elementDeclSAXFunc)(void *ctx,
476 const xmlChar *name,
477 int type,
478 xmlElementContentPtr content);
490 const xmlChar *name,
491 const xmlChar *publicId,
492 const xmlChar *systemId,
493 const xmlChar *notationName);
503 xmlSAXLocatorPtr loc);
510typedef void (*startDocumentSAXFunc) (void *ctx);
517typedef void (*endDocumentSAXFunc) (void *ctx);
526typedef void (*startElementSAXFunc) (void *ctx,
527 const xmlChar *name,
528 const xmlChar **atts);
536typedef void (*endElementSAXFunc) (void *ctx,
537 const xmlChar *name);
549typedef void (*attributeSAXFunc) (void *ctx,
550 const xmlChar *name,
551 const xmlChar *value);
559typedef void (*referenceSAXFunc) (void *ctx,
560 const xmlChar *name);
569typedef void (*charactersSAXFunc) (void *ctx,
570 const xmlChar *ch,
571 int len);
582 const xmlChar *ch,
583 int len);
593 const xmlChar *target,
594 const xmlChar *data);
602typedef void (*commentSAXFunc) (void *ctx,
603 const xmlChar *value);
613 void *ctx,
614 const xmlChar *value,
615 int len);
624typedef void (*warningSAXFunc) (void *ctx,
625 const char *msg, ...) LIBXML_ATTR_FORMAT(2,3);
634typedef void (*errorSAXFunc) (void *ctx,
635 const char *msg, ...) LIBXML_ATTR_FORMAT(2,3);
646typedef void (*fatalErrorSAXFunc) (void *ctx,
647 const char *msg, ...) LIBXML_ATTR_FORMAT(2,3);
656typedef int (*isStandaloneSAXFunc) (void *ctx);
666
676
677/************************************************************************
678 * *
679 * The SAX version 2 API extensions *
680 * *
681 ************************************************************************/
687#define XML_SAX2_MAGIC 0xDEEDBEAF
688
709 const xmlChar *localname,
710 const xmlChar *prefix,
711 const xmlChar *URI,
712 int nb_namespaces,
713 const xmlChar **namespaces,
714 int nb_attributes,
715 int nb_defaulted,
716 const xmlChar **attributes);
717
729typedef void (*endElementNsSAX2Func) (void *ctx,
730 const xmlChar *localname,
731 const xmlChar *prefix,
732 const xmlChar *URI);
733
734
750 /*
751 * `startElement` and `endElement` are only used by the legacy SAX1
752 * interface and should not be used in new software. If you really
753 * have to enable SAX1, the preferred way is set the `initialized`
754 * member to 1 instead of XML_SAX2_MAGIC.
755 *
756 * For backward compatibility, it's also possible to set the
757 * `startElementNs` and `endElementNs` handlers to NULL.
758 *
759 * You can also set the XML_PARSE_SAX1 parser option, but versions
760 * older than 2.12.0 will probably crash if this option is provided
761 * together with custom SAX callbacks.
762 */
772 fatalErrorSAXFunc fatalError; /* unused error() get all the errors */
776 /*
777 * `initialized` should always be set to XML_SAX2_MAGIC to enable the
778 * modern SAX2 interface.
779 */
780 unsigned int initialized;
781 /*
782 * The following members are only used by the SAX2 interface.
783 */
784 void *_private;
788};
789
790/*
791 * SAX Version 1
792 */
819 fatalErrorSAXFunc fatalError; /* unused error() get all the errors */
823 unsigned int initialized;
824};
825
826
837typedef xmlParserInputPtr (*xmlExternalEntityLoader) (const char *URL,
838 const char *ID,
839 xmlParserCtxtPtr context);
840
841/*
842 * Variables
843 */
844
845XMLPUBVAR const char *const xmlParserVersion;
846#ifdef LIBXML_THREAD_ENABLED
847/* backward compatibility */
848XMLPUBFUN const char *const *__xmlParserVersion(void);
849#endif
850
852#define XML_GLOBALS_PARSER_CORE \
853 XML_OP(oldXMLWDcompatibility, int, XML_DEPRECATED) \
854 XML_OP(xmlDefaultSAXLocator, xmlSAXLocator, XML_DEPRECATED) \
855 XML_OP(xmlDoValidityCheckingDefaultValue, int, XML_DEPRECATED) \
856 XML_OP(xmlGetWarningsDefaultValue, int, XML_DEPRECATED) \
857 XML_OP(xmlKeepBlanksDefaultValue, int, XML_DEPRECATED) \
858 XML_OP(xmlLineNumbersDefaultValue, int, XML_DEPRECATED) \
859 XML_OP(xmlLoadExtDtdDefaultValue, int, XML_DEPRECATED) \
860 XML_OP(xmlParserDebugEntities, int, XML_DEPRECATED) \
861 XML_OP(xmlPedanticParserDefaultValue, int, XML_DEPRECATED) \
862 XML_OP(xmlSubstituteEntitiesDefaultValue, int, XML_DEPRECATED)
863
864#ifdef LIBXML_OUTPUT_ENABLED
865 #define XML_GLOBALS_PARSER_OUTPUT \
866 XML_OP(xmlIndentTreeOutput, int, XML_NO_ATTR) \
867 XML_OP(xmlTreeIndentString, const char *, XML_NO_ATTR) \
868 XML_OP(xmlSaveNoEmptyTags, int, XML_NO_ATTR)
869#else
870 #define XML_GLOBALS_PARSER_OUTPUT
871#endif
872
873#ifdef LIBXML_SAX1_ENABLED
874 #define XML_GLOBALS_PARSER_SAX1 \
875 XML_OP(xmlDefaultSAXHandler, xmlSAXHandlerV1, XML_DEPRECATED)
876#else
877 #define XML_GLOBALS_PARSER_SAX1
878#endif
879
880#define XML_GLOBALS_PARSER \
881 XML_GLOBALS_PARSER_CORE \
882 XML_GLOBALS_PARSER_OUTPUT \
883 XML_GLOBALS_PARSER_SAX1
884
885#define XML_OP XML_DECLARE_GLOBAL
887#undef XML_OP
888
889#if defined(LIBXML_THREAD_ENABLED) && !defined(XML_GLOBALS_NO_REDEFINITION)
890 #define oldXMLWDcompatibility XML_GLOBAL_MACRO(oldXMLWDcompatibility)
891 #define xmlDefaultSAXHandler XML_GLOBAL_MACRO(xmlDefaultSAXHandler)
892 #define xmlDefaultSAXLocator XML_GLOBAL_MACRO(xmlDefaultSAXLocator)
893 #define xmlDoValidityCheckingDefaultValue \
894 XML_GLOBAL_MACRO(xmlDoValidityCheckingDefaultValue)
895 #define xmlGetWarningsDefaultValue \
896 XML_GLOBAL_MACRO(xmlGetWarningsDefaultValue)
897 #define xmlKeepBlanksDefaultValue XML_GLOBAL_MACRO(xmlKeepBlanksDefaultValue)
898 #define xmlLineNumbersDefaultValue \
899 XML_GLOBAL_MACRO(xmlLineNumbersDefaultValue)
900 #define xmlLoadExtDtdDefaultValue XML_GLOBAL_MACRO(xmlLoadExtDtdDefaultValue)
901 #define xmlParserDebugEntities XML_GLOBAL_MACRO(xmlParserDebugEntities)
902 #define xmlPedanticParserDefaultValue \
903 XML_GLOBAL_MACRO(xmlPedanticParserDefaultValue)
904 #define xmlSubstituteEntitiesDefaultValue \
905 XML_GLOBAL_MACRO(xmlSubstituteEntitiesDefaultValue)
906 #ifdef LIBXML_OUTPUT_ENABLED
907 #define xmlIndentTreeOutput XML_GLOBAL_MACRO(xmlIndentTreeOutput)
908 #define xmlTreeIndentString XML_GLOBAL_MACRO(xmlTreeIndentString)
909 #define xmlSaveNoEmptyTags XML_GLOBAL_MACRO(xmlSaveNoEmptyTags)
910 #endif
911#endif
914/*
915 * Init/Cleanup
916 */
917XMLPUBFUN void
918 xmlInitParser (void);
919XMLPUBFUN void
920 xmlCleanupParser (void);
922XMLPUBFUN void
923 xmlInitGlobals (void);
925XMLPUBFUN void
926 xmlCleanupGlobals (void);
927
928/*
929 * Input functions
930 */
932XMLPUBFUN int
933 xmlParserInputRead (xmlParserInputPtr in,
934 int len);
936XMLPUBFUN int
937 xmlParserInputGrow (xmlParserInputPtr in,
938 int len);
939
940/*
941 * Basic parsing Interfaces
942 */
943#ifdef LIBXML_SAX1_ENABLED
944XMLPUBFUN xmlDocPtr
945 xmlParseDoc (const xmlChar *cur);
946XMLPUBFUN xmlDocPtr
947 xmlParseFile (const char *filename);
948XMLPUBFUN xmlDocPtr
949 xmlParseMemory (const char *buffer,
950 int size);
951#endif /* LIBXML_SAX1_ENABLED */
960XMLPUBFUN void
961 xmlStopParser (xmlParserCtxtPtr ctxt);
978
979#ifdef LIBXML_SAX1_ENABLED
980/*
981 * Recovery mode
982 */
984XMLPUBFUN xmlDocPtr
985 xmlRecoverDoc (const xmlChar *cur);
987XMLPUBFUN xmlDocPtr
988 xmlRecoverMemory (const char *buffer,
989 int size);
991XMLPUBFUN xmlDocPtr
992 xmlRecoverFile (const char *filename);
993#endif /* LIBXML_SAX1_ENABLED */
994
995/*
996 * Less common routines and SAX interfaces
997 */
998XMLPUBFUN int
999 xmlParseDocument (xmlParserCtxtPtr ctxt);
1000XMLPUBFUN int
1001 xmlParseExtParsedEnt (xmlParserCtxtPtr ctxt);
1002#ifdef LIBXML_SAX1_ENABLED
1004XMLPUBFUN int
1005 xmlSAXUserParseFile (xmlSAXHandlerPtr sax,
1006 void *user_data,
1007 const char *filename);
1009XMLPUBFUN int
1010 xmlSAXUserParseMemory (xmlSAXHandlerPtr sax,
1011 void *user_data,
1012 const char *buffer,
1013 int size);
1015XMLPUBFUN xmlDocPtr
1016 xmlSAXParseDoc (xmlSAXHandlerPtr sax,
1017 const xmlChar *cur,
1018 int recovery);
1020XMLPUBFUN xmlDocPtr
1021 xmlSAXParseMemory (xmlSAXHandlerPtr sax,
1022 const char *buffer,
1023 int size,
1024 int recovery);
1026XMLPUBFUN xmlDocPtr
1027 xmlSAXParseMemoryWithData (xmlSAXHandlerPtr sax,
1028 const char *buffer,
1029 int size,
1030 int recovery,
1031 void *data);
1033XMLPUBFUN xmlDocPtr
1034 xmlSAXParseFile (xmlSAXHandlerPtr sax,
1035 const char *filename,
1036 int recovery);
1038XMLPUBFUN xmlDocPtr
1039 xmlSAXParseFileWithData (xmlSAXHandlerPtr sax,
1040 const char *filename,
1041 int recovery,
1042 void *data);
1044XMLPUBFUN xmlDocPtr
1045 xmlSAXParseEntity (xmlSAXHandlerPtr sax,
1046 const char *filename);
1048XMLPUBFUN xmlDocPtr
1049 xmlParseEntity (const char *filename);
1050#endif /* LIBXML_SAX1_ENABLED */
1051
1052#ifdef LIBXML_VALID_ENABLED
1054XMLPUBFUN xmlDtdPtr
1055 xmlSAXParseDTD (xmlSAXHandlerPtr sax,
1056 const xmlChar *ExternalID,
1057 const xmlChar *SystemID);
1058XMLPUBFUN xmlDtdPtr
1059 xmlParseDTD (const xmlChar *ExternalID,
1060 const xmlChar *SystemID);
1061XMLPUBFUN xmlDtdPtr
1062 xmlIOParseDTD (xmlSAXHandlerPtr sax,
1063 xmlParserInputBufferPtr input,
1064 xmlCharEncoding enc);
1065#endif /* LIBXML_VALID_ENABLE */
1066#ifdef LIBXML_SAX1_ENABLED
1067XMLPUBFUN int
1068 xmlParseBalancedChunkMemory(xmlDocPtr doc,
1069 xmlSAXHandlerPtr sax,
1070 void *user_data,
1071 int depth,
1072 const xmlChar *string,
1073 xmlNodePtr *lst);
1074#endif /* LIBXML_SAX1_ENABLED */
1076 xmlParseInNodeContext (xmlNodePtr node,
1077 const char *data,
1078 int datalen,
1079 int options,
1080 xmlNodePtr *lst);
1081#ifdef LIBXML_SAX1_ENABLED
1082XMLPUBFUN int
1083 xmlParseBalancedChunkMemoryRecover(xmlDocPtr doc,
1084 xmlSAXHandlerPtr sax,
1085 void *user_data,
1086 int depth,
1087 const xmlChar *string,
1088 xmlNodePtr *lst,
1089 int recover);
1091XMLPUBFUN int
1092 xmlParseExternalEntity (xmlDocPtr doc,
1093 xmlSAXHandlerPtr sax,
1094 void *user_data,
1095 int depth,
1096 const xmlChar *URL,
1097 const xmlChar *ID,
1098 xmlNodePtr *lst);
1099#endif /* LIBXML_SAX1_ENABLED */
1100XMLPUBFUN int
1101 xmlParseCtxtExternalEntity(xmlParserCtxtPtr ctx,
1102 const xmlChar *URL,
1103 const xmlChar *ID,
1104 xmlNodePtr *lst);
1105
1106/*
1107 * Parser contexts handling.
1108 */
1109XMLPUBFUN xmlParserCtxtPtr
1110 xmlNewParserCtxt (void);
1111XMLPUBFUN xmlParserCtxtPtr
1112 xmlNewSAXParserCtxt (const xmlSAXHandler *sax,
1113 void *userData);
1114XMLPUBFUN int
1115 xmlInitParserCtxt (xmlParserCtxtPtr ctxt);
1116XMLPUBFUN void
1117 xmlClearParserCtxt (xmlParserCtxtPtr ctxt);
1118XMLPUBFUN void
1119 xmlFreeParserCtxt (xmlParserCtxtPtr ctxt);
1120#ifdef LIBXML_SAX1_ENABLED
1122XMLPUBFUN void
1123 xmlSetupParserForBuffer (xmlParserCtxtPtr ctxt,
1124 const xmlChar* buffer,
1125 const char *filename);
1126#endif /* LIBXML_SAX1_ENABLED */
1127XMLPUBFUN xmlParserCtxtPtr
1129
1130#ifdef LIBXML_LEGACY_ENABLED
1131/*
1132 * Reading/setting optional parsing features.
1133 */
1135XMLPUBFUN int
1136 xmlGetFeaturesList (int *len,
1137 const char **result);
1139XMLPUBFUN int
1140 xmlGetFeature (xmlParserCtxtPtr ctxt,
1141 const char *name,
1142 void *result);
1144XMLPUBFUN int
1145 xmlSetFeature (xmlParserCtxtPtr ctxt,
1146 const char *name,
1147 void *value);
1148#endif /* LIBXML_LEGACY_ENABLED */
1149
1150#ifdef LIBXML_PUSH_ENABLED
1151/*
1152 * Interfaces for the Push mode.
1153 */
1154XMLPUBFUN xmlParserCtxtPtr
1155 xmlCreatePushParserCtxt(xmlSAXHandlerPtr sax,
1156 void *user_data,
1157 const char *chunk,
1158 int size,
1159 const char *filename);
1160XMLPUBFUN int
1161 xmlParseChunk (xmlParserCtxtPtr ctxt,
1162 const char *chunk,
1163 int size,
1164 int terminate);
1165#endif /* LIBXML_PUSH_ENABLED */
1166
1167/*
1168 * Special I/O mode.
1169 */
1170
1171XMLPUBFUN xmlParserCtxtPtr
1172 xmlCreateIOParserCtxt (xmlSAXHandlerPtr sax,
1173 void *user_data,
1174 xmlInputReadCallback ioread,
1175 xmlInputCloseCallback ioclose,
1176 void *ioctx,
1177 xmlCharEncoding enc);
1178
1179XMLPUBFUN xmlParserInputPtr
1180 xmlNewIOInputStream (xmlParserCtxtPtr ctxt,
1181 xmlParserInputBufferPtr input,
1182 xmlCharEncoding enc);
1183
1184/*
1185 * Node infos.
1186 */
1188 xmlParserFindNodeInfo (const xmlParserCtxtPtr ctxt,
1189 const xmlNodePtr node);
1190XMLPUBFUN void
1192XMLPUBFUN void
1194XMLPUBFUN unsigned long
1196 const xmlNodePtr node);
1197XMLPUBFUN void
1198 xmlParserAddNodeInfo (xmlParserCtxtPtr ctxt,
1200
1201/*
1202 * External entities handling actually implemented in xmlIO.
1203 */
1204
1205XMLPUBFUN void
1209XMLPUBFUN xmlParserInputPtr
1210 xmlLoadExternalEntity (const char *URL,
1211 const char *ID,
1212 xmlParserCtxtPtr ctxt);
1213
1214/*
1215 * Index lookup, actually implemented in the encoding module
1216 */
1217XMLPUBFUN long
1218 xmlByteConsumed (xmlParserCtxtPtr ctxt);
1219
1220/*
1221 * New set of simpler/more flexible APIs
1222 */
1229typedef enum {
1230 XML_PARSE_RECOVER = 1<<0, /* recover on errors */
1231 XML_PARSE_NOENT = 1<<1, /* substitute entities */
1232 XML_PARSE_DTDLOAD = 1<<2, /* load the external subset */
1233 XML_PARSE_DTDATTR = 1<<3, /* default DTD attributes */
1234 XML_PARSE_DTDVALID = 1<<4, /* validate with the DTD */
1235 XML_PARSE_NOERROR = 1<<5, /* suppress error reports */
1236 XML_PARSE_NOWARNING = 1<<6, /* suppress warning reports */
1237 XML_PARSE_PEDANTIC = 1<<7, /* pedantic error reporting */
1238 XML_PARSE_NOBLANKS = 1<<8, /* remove blank nodes */
1239 XML_PARSE_SAX1 = 1<<9, /* use the SAX1 interface internally */
1240 XML_PARSE_XINCLUDE = 1<<10,/* Implement XInclude substitution */
1241 XML_PARSE_NONET = 1<<11,/* Forbid network access */
1242 XML_PARSE_NODICT = 1<<12,/* Do not reuse the context dictionary */
1243 XML_PARSE_NSCLEAN = 1<<13,/* remove redundant namespaces declarations */
1244 XML_PARSE_NOCDATA = 1<<14,/* merge CDATA as text nodes */
1245 XML_PARSE_NOXINCNODE= 1<<15,/* do not generate XINCLUDE START/END nodes */
1246 XML_PARSE_COMPACT = 1<<16,/* compact small text nodes; no modification of
1247 the tree allowed afterwards (will possibly
1248 crash if you try to modify the tree) */
1249 XML_PARSE_OLD10 = 1<<17,/* parse using XML-1.0 before update 5 */
1250 XML_PARSE_NOBASEFIX = 1<<18,/* do not fixup XINCLUDE xml:base uris */
1251 XML_PARSE_HUGE = 1<<19,/* relax any hardcoded limit from the parser */
1252 XML_PARSE_OLDSAX = 1<<20,/* parse using SAX2 interface before 2.7.0 */
1253 XML_PARSE_IGNORE_ENC= 1<<21,/* ignore internal document encoding hint */
1254 XML_PARSE_BIG_LINES = 1<<22 /* Store big lines numbers in text PSVI field */
1256
1257XMLPUBFUN void
1258 xmlCtxtReset (xmlParserCtxtPtr ctxt);
1259XMLPUBFUN int
1260 xmlCtxtResetPush (xmlParserCtxtPtr ctxt,
1261 const char *chunk,
1262 int size,
1263 const char *filename,
1264 const char *encoding);
1265XMLPUBFUN int
1266 xmlCtxtUseOptions (xmlParserCtxtPtr ctxt,
1267 int options);
1268XMLPUBFUN void
1269 xmlCtxtSetMaxAmplification(xmlParserCtxtPtr ctxt,
1270 unsigned maxAmpl);
1271XMLPUBFUN xmlDocPtr
1272 xmlReadDoc (const xmlChar *cur,
1273 const char *URL,
1274 const char *encoding,
1275 int options);
1276XMLPUBFUN xmlDocPtr
1277 xmlReadFile (const char *URL,
1278 const char *encoding,
1279 int options);
1280XMLPUBFUN xmlDocPtr
1281 xmlReadMemory (const char *buffer,
1282 int size,
1283 const char *URL,
1284 const char *encoding,
1285 int options);
1286XMLPUBFUN xmlDocPtr
1287 xmlReadFd (int fd,
1288 const char *URL,
1289 const char *encoding,
1290 int options);
1291XMLPUBFUN xmlDocPtr
1293 xmlInputCloseCallback ioclose,
1294 void *ioctx,
1295 const char *URL,
1296 const char *encoding,
1297 int options);
1298XMLPUBFUN xmlDocPtr
1299 xmlCtxtReadDoc (xmlParserCtxtPtr ctxt,
1300 const xmlChar *cur,
1301 const char *URL,
1302 const char *encoding,
1303 int options);
1304XMLPUBFUN xmlDocPtr
1305 xmlCtxtReadFile (xmlParserCtxtPtr ctxt,
1306 const char *filename,
1307 const char *encoding,
1308 int options);
1309XMLPUBFUN xmlDocPtr
1310 xmlCtxtReadMemory (xmlParserCtxtPtr ctxt,
1311 const char *buffer,
1312 int size,
1313 const char *URL,
1314 const char *encoding,
1315 int options);
1316XMLPUBFUN xmlDocPtr
1317 xmlCtxtReadFd (xmlParserCtxtPtr ctxt,
1318 int fd,
1319 const char *URL,
1320 const char *encoding,
1321 int options);
1322XMLPUBFUN xmlDocPtr
1323 xmlCtxtReadIO (xmlParserCtxtPtr ctxt,
1324 xmlInputReadCallback ioread,
1325 xmlInputCloseCallback ioclose,
1326 void *ioctx,
1327 const char *URL,
1328 const char *encoding,
1329 int options);
1330
1331/*
1332 * Library wide options
1333 */
1341typedef enum {
1375 XML_WITH_NONE = 99999 /* just to be sure of allocation size */
1377
1378XMLPUBFUN int
1380
1381#ifdef __cplusplus
1382}
1383#endif
1384#endif /* __XML_PARSER_H__ */
#define msg(x)
Definition: auth_time.c:54
struct _tree tree
_In_ uint16_t _Out_ ULONG * atts
Definition: btrfs_drv.h:1107
content
Definition: atl_ax.c:994
unsigned char ch[4][2]
Definition: console.c:118
void CDECL terminate(void)
Definition: cpp.c:698
unsigned int(__cdecl typeof(jpeg_read_scanlines))(struct jpeg_decompress_struct *
Definition: typeof.h:31
xmlCharEncoding
Definition: encoding.h:65
FxCollectionEntry * cur
GLint GLint GLsizei GLsizei GLsizei depth
Definition: gl.h:1546
const GLdouble * v
Definition: gl.h:2040
GLuint GLuint GLsizei GLenum type
Definition: gl.h:1545
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
Definition: gl.h:1950
GLuint buffer
Definition: glext.h:5915
GLsizeiptr size
Definition: glext.h:5919
GLfloat f
Definition: glext.h:7540
GLuint in
Definition: glext.h:9616
GLuint GLfloat * val
Definition: glext.h:7180
GLuint64EXT * result
Definition: glext.h:11304
GLenum GLsizei len
Definition: glext.h:6722
GLenum GLenum GLenum input
Definition: glext.h:9031
const char * filename
Definition: ioapi.h:137
int const JOCTET unsigned int datalen
Definition: jpeglib.h:1031
const char * fullname
Definition: shader.c:1766
static size_t elem
Definition: string.c:71
INTERNETFEATURELIST feature
Definition: misc.c:1719
const WCHAR * str
#define ID
Definition: ruserpass.c:36
XMLPUBFUN int xmlParseDocument(xmlParserCtxtPtr ctxt)
Definition: parser.c:11009
xmlParserInputState
Definition: parser.h:115
@ XML_PARSER_END_TAG
Definition: parser.h:126
@ XML_PARSER_PROLOG
Definition: parser.h:121
@ XML_PARSER_IGNORE
Definition: parser.h:132
@ XML_PARSER_PUBLIC_LITERAL
Definition: parser.h:133
@ XML_PARSER_PI
Definition: parser.h:119
@ XML_PARSER_SYSTEM_LITERAL
Definition: parser.h:130
@ XML_PARSER_ATTRIBUTE_VALUE
Definition: parser.h:129
@ XML_PARSER_DTD
Definition: parser.h:120
@ XML_PARSER_EOF
Definition: parser.h:116
@ XML_PARSER_START_TAG
Definition: parser.h:123
@ XML_PARSER_CONTENT
Definition: parser.h:124
@ XML_PARSER_ENTITY_VALUE
Definition: parser.h:128
@ XML_PARSER_EPILOG
Definition: parser.h:131
@ XML_PARSER_START
Definition: parser.h:117
@ XML_PARSER_COMMENT
Definition: parser.h:122
@ XML_PARSER_CDATA_SECTION
Definition: parser.h:125
@ XML_PARSER_XML_DECL
Definition: parser.h:134
@ XML_PARSER_MISC
Definition: parser.h:118
@ XML_PARSER_ENTITY_DECL
Definition: parser.h:127
void(* startElementNsSAX2Func)(void *ctx, const xmlChar *localname, const xmlChar *prefix, const xmlChar *URI, int nb_namespaces, const xmlChar **namespaces, int nb_attributes, int nb_defaulted, const xmlChar **attributes)
Definition: parser.h:708
void(*) typedef void(* errorSAXFunc)(void *ctx, const char *msg,...) LIBXML_ATTR_FORMAT(2
Definition: parser.h:634
void(* cdataBlockSAXFunc)(void *ctx, const xmlChar *value, int len)
Definition: parser.h:612
XMLPUBFUN xmlDocPtr xmlReadFd(int fd, const char *URL, const char *encoding, int options)
Definition: parser.c:14860
XML_DEPRECATED XMLPUBFUN int xmlThrDefParserDebugEntities(int v)
Definition: globals.c:1118
XMLPUBFUN int xmlCtxtUseOptions(xmlParserCtxtPtr ctxt, int options)
Definition: parser.c:14698
void(*) typedef void(*) typedef void(* fatalErrorSAXFunc)(void *ctx, const char *msg,...) LIBXML_ATTR_FORMAT(2
Definition: parser.h:646
XMLPUBVAR const char *const xmlParserVersion
Definition: parser.h:845
XML_DEPRECATED XMLPUBFUN int xmlThrDefDoValidityCheckingDefaultValue(int v)
Definition: globals.c:1044
XMLPUBFUN int xmlHasFeature(xmlFeature feature)
Definition: parser.c:640
XMLPUBFUN xmlParserInputPtr xmlLoadExternalEntity(const char *URL, const char *ID, xmlParserCtxtPtr ctxt)
XML_DEPRECATED XMLPUBFUN void xmlCleanupGlobals(void)
Definition: globals.c:609
void(* internalSubsetSAXFunc)(void *ctx, const xmlChar *name, const xmlChar *ExternalID, const xmlChar *SystemID)
Definition: parser.h:378
XML_DEPRECATED XMLPUBFUN int xmlKeepBlanksDefault(int val)
XML_DEPRECATED XMLPUBFUN int xmlParserInputRead(xmlParserInputPtr in, int len)
XML_DEPRECATED XMLPUBFUN int xmlSubstituteEntitiesDefault(int val)
XML_GLOBALS_PARSER XMLPUBFUN void xmlInitParser(void)
Definition: threads.c:569
XMLPUBFUN long xmlByteConsumed(xmlParserCtxtPtr ctxt)
XMLPUBFUN const xmlParserNodeInfo * xmlParserFindNodeInfo(const xmlParserCtxtPtr ctxt, const xmlNodePtr node)
XMLPUBFUN void xmlInitNodeInfoSeq(xmlParserNodeInfoSeqPtr seq)
XMLPUBFUN xmlDocPtr xmlCtxtReadDoc(xmlParserCtxtPtr ctxt, const xmlChar *cur, const char *URL, const char *encoding, int options)
Definition: parser.c:14950
XMLPUBFUN void xmlParserAddNodeInfo(xmlParserCtxtPtr ctxt, const xmlParserNodeInfoPtr info)
void(* startDocumentSAXFunc)(void *ctx)
Definition: parser.h:510
XMLPUBFUN xmlDocPtr xmlCtxtReadFile(xmlParserCtxtPtr ctxt, const char *filename, const char *encoding, int options)
Definition: parser.c:14992
XMLPUBFUN xmlExternalEntityLoader xmlGetExternalEntityLoader(void)
XMLPUBFUN xmlParserCtxtPtr xmlNewSAXParserCtxt(const xmlSAXHandler *sax, void *userData)
void(* commentSAXFunc)(void *ctx, const xmlChar *value)
Definition: parser.h:602
XMLPUBFUN xmlParserErrors xmlParseInNodeContext(xmlNodePtr node, const char *data, int datalen, int options, xmlNodePtr *lst)
Definition: parser.c:13156
XML_DEPRECATED XMLPUBFUN int xmlThrDefKeepBlanksDefaultValue(int v)
Definition: globals.c:1091
XMLPUBFUN unsigned long xmlParserFindNodeInfoIndex(const xmlParserNodeInfoSeqPtr seq, const xmlNodePtr node)
void(* attributeSAXFunc)(void *ctx, const xmlChar *name, const xmlChar *value)
Definition: parser.h:549
XMLPUBFUN xmlDocPtr xmlReadMemory(const char *buffer, int size, const char *URL, const char *encoding, int options)
Definition: parser.c:14835
void(* unparsedEntityDeclSAXFunc)(void *ctx, const xmlChar *name, const xmlChar *publicId, const xmlChar *systemId, const xmlChar *notationName)
Definition: parser.h:489
void(* elementDeclSAXFunc)(void *ctx, const xmlChar *name, int type, xmlElementContentPtr content)
Definition: parser.h:475
xmlEntityPtr(* getParameterEntitySAXFunc)(void *ctx, const xmlChar *name)
Definition: parser.h:415
void(* processingInstructionSAXFunc)(void *ctx, const xmlChar *target, const xmlChar *data)
Definition: parser.h:592
XMLPUBFUN xmlDocPtr xmlCtxtReadIO(xmlParserCtxtPtr ctxt, xmlInputReadCallback ioread, xmlInputCloseCallback ioclose, void *ioctx, const char *URL, const char *encoding, int options)
Definition: parser.c:15118
XMLPUBFUN void xmlFreeParserCtxt(xmlParserCtxtPtr ctxt)
xmlEntityPtr(* getEntitySAXFunc)(void *ctx, const xmlChar *name)
Definition: parser.h:404
xmlParserInputPtr(* resolveEntitySAXFunc)(void *ctx, const xmlChar *publicId, const xmlChar *systemId)
Definition: parser.h:366
XML_DEPRECATED XMLPUBFUN int xmlPedanticParserDefault(int val)
XML_DEPRECATED XMLPUBFUN int xmlThrDefLoadExtDtdDefaultValue(int v)
Definition: globals.c:1109
XMLPUBFUN xmlDocPtr xmlCtxtReadMemory(xmlParserCtxtPtr ctxt, const char *buffer, int size, const char *URL, const char *encoding, int options)
Definition: parser.c:15028
XML_DEPRECATED XMLPUBFUN int xmlThrDefPedanticParserDefaultValue(int v)
Definition: globals.c:1127
void(* warningSAXFunc)(void *ctx, const char *msg,...) LIBXML_ATTR_FORMAT(2
Definition: parser.h:624
xmlParserOption
Definition: parser.h:1229
@ XML_PARSE_SAX1
Definition: parser.h:1239
@ XML_PARSE_DTDVALID
Definition: parser.h:1234
@ XML_PARSE_NOWARNING
Definition: parser.h:1236
@ XML_PARSE_NOCDATA
Definition: parser.h:1244
@ XML_PARSE_COMPACT
Definition: parser.h:1246
@ XML_PARSE_NONET
Definition: parser.h:1241
@ XML_PARSE_NOBLANKS
Definition: parser.h:1238
@ XML_PARSE_IGNORE_ENC
Definition: parser.h:1253
@ XML_PARSE_NOBASEFIX
Definition: parser.h:1250
@ XML_PARSE_DTDLOAD
Definition: parser.h:1232
@ XML_PARSE_XINCLUDE
Definition: parser.h:1240
@ XML_PARSE_RECOVER
Definition: parser.h:1230
@ XML_PARSE_HUGE
Definition: parser.h:1251
@ XML_PARSE_NODICT
Definition: parser.h:1242
@ XML_PARSE_BIG_LINES
Definition: parser.h:1254
@ XML_PARSE_DTDATTR
Definition: parser.h:1233
@ XML_PARSE_OLD10
Definition: parser.h:1249
@ XML_PARSE_OLDSAX
Definition: parser.h:1252
@ XML_PARSE_NOERROR
Definition: parser.h:1235
@ XML_PARSE_NOXINCNODE
Definition: parser.h:1245
@ XML_PARSE_NOENT
Definition: parser.h:1231
@ XML_PARSE_PEDANTIC
Definition: parser.h:1237
@ XML_PARSE_NSCLEAN
Definition: parser.h:1243
void(*) typedef void(*) typedef void(*) typedef int(* isStandaloneSAXFunc)(void *ctx)
Definition: parser.h:656
void(* charactersSAXFunc)(void *ctx, const xmlChar *ch, int len)
Definition: parser.h:569
#define XML_GLOBALS_PARSER
Definition: parser.h:880
XMLPUBFUN int xmlParseExtParsedEnt(xmlParserCtxtPtr ctxt)
Definition: parser.c:11179
XML_DEPRECATED XMLPUBFUN void xmlInitGlobals(void)
Definition: globals.c:562
void(* entityDeclSAXFunc)(void *ctx, const xmlChar *name, int type, const xmlChar *publicId, const xmlChar *systemId, xmlChar *content)
Definition: parser.h:428
xmlSAXHandlerV1 * xmlSAXHandlerV1Ptr
Definition: parser.h:794
XMLPUBFUN void xmlCtxtSetMaxAmplification(xmlParserCtxtPtr ctxt, unsigned maxAmpl)
Definition: parser.c:14717
int(* hasExternalSubsetSAXFunc)(void *ctx)
Definition: parser.h:675
void(* setDocumentLocatorSAXFunc)(void *ctx, xmlSAXLocatorPtr loc)
Definition: parser.h:502
void(* xmlParserInputDeallocate)(xmlChar *str)
Definition: parser.h:58
XMLPUBFUN void xmlCleanupParser(void)
Definition: threads.c:630
void(* attributeDeclSAXFunc)(void *ctx, const xmlChar *elem, const xmlChar *fullname, int type, int def, const xmlChar *defaultValue, xmlEnumerationPtr tree)
Definition: parser.h:459
XMLPUBFUN void xmlClearParserCtxt(xmlParserCtxtPtr ctxt)
XMLPUBFUN void xmlClearNodeInfoSeq(xmlParserNodeInfoSeqPtr seq)
XMLPUBFUN xmlParserCtxtPtr xmlCreateDocParserCtxt(const xmlChar *cur)
Definition: parser.c:14207
XMLPUBFUN xmlDocPtr xmlReadIO(xmlInputReadCallback ioread, xmlInputCloseCallback ioclose, void *ioctx, const char *URL, const char *encoding, int options)
Definition: parser.c:14903
XMLPUBFUN xmlParserCtxtPtr xmlCreateIOParserCtxt(xmlSAXHandlerPtr sax, void *user_data, xmlInputReadCallback ioread, xmlInputCloseCallback ioclose, void *ioctx, xmlCharEncoding enc)
Definition: parser.c:12333
int(* hasInternalSubsetSAXFunc)(void *ctx)
Definition: parser.h:665
void(* ignorableWhitespaceSAXFunc)(void *ctx, const xmlChar *ch, int len)
Definition: parser.h:581
void(* endElementSAXFunc)(void *ctx, const xmlChar *name)
Definition: parser.h:536
XMLPUBFUN int xmlInitParserCtxt(xmlParserCtxtPtr ctxt)
XML_DEPRECATED XMLPUBFUN int xmlThrDefGetWarningsDefaultValue(int v)
Definition: globals.c:1053
xmlParserNodeInfo * xmlParserNodeInfoPtr
Definition: parser.h:90
xmlFeature
Definition: parser.h:1341
@ XML_WITH_DEBUG
Definition: parser.h:1369
@ XML_WITH_LEGACY
Definition: parser.h:1354
@ XML_WITH_CATALOG
Definition: parser.h:1356
@ XML_WITH_XPATH
Definition: parser.h:1357
@ XML_WITH_TREE
Definition: parser.h:1343
@ XML_WITH_DEBUG_MEM
Definition: parser.h:1370
@ XML_WITH_DEBUG_RUN
Definition: parser.h:1371
@ XML_WITH_XPTR
Definition: parser.h:1358
@ XML_WITH_OUTPUT
Definition: parser.h:1344
@ XML_WITH_EXPR
Definition: parser.h:1365
@ XML_WITH_VALID
Definition: parser.h:1352
@ XML_WITH_THREAD
Definition: parser.h:1342
@ XML_WITH_SCHEMAS
Definition: parser.h:1366
@ XML_WITH_C14N
Definition: parser.h:1355
@ XML_WITH_MODULES
Definition: parser.h:1368
@ XML_WITH_NONE
Definition: parser.h:1375
@ XML_WITH_UNICODE
Definition: parser.h:1362
@ XML_WITH_REGEXP
Definition: parser.h:1363
@ XML_WITH_HTML
Definition: parser.h:1353
@ XML_WITH_LZMA
Definition: parser.h:1374
@ XML_WITH_AUTOMATA
Definition: parser.h:1364
@ XML_WITH_ISO8859X
Definition: parser.h:1361
@ XML_WITH_PUSH
Definition: parser.h:1345
@ XML_WITH_ICONV
Definition: parser.h:1360
@ XML_WITH_ZLIB
Definition: parser.h:1372
@ XML_WITH_SAX1
Definition: parser.h:1349
@ XML_WITH_PATTERN
Definition: parser.h:1347
@ XML_WITH_WRITER
Definition: parser.h:1348
@ XML_WITH_FTP
Definition: parser.h:1350
@ XML_WITH_HTTP
Definition: parser.h:1351
@ XML_WITH_READER
Definition: parser.h:1346
@ XML_WITH_XINCLUDE
Definition: parser.h:1359
@ XML_WITH_SCHEMATRON
Definition: parser.h:1367
@ XML_WITH_ICU
Definition: parser.h:1373
XML_DEPRECATED XMLPUBFUN int xmlThrDefSubstituteEntitiesDefaultValue(int v)
Definition: globals.c:1136
XMLPUBFUN xmlParserCtxtPtr xmlNewParserCtxt(void)
void(* endDocumentSAXFunc)(void *ctx)
Definition: parser.h:517
void(* startElementSAXFunc)(void *ctx, const xmlChar *name, const xmlChar **atts)
Definition: parser.h:526
XMLPUBFUN int xmlCtxtResetPush(xmlParserCtxtPtr ctxt, const char *chunk, int size, const char *filename, const char *encoding)
Definition: parser.c:14480
XMLPUBFUN xmlDocPtr xmlCtxtReadFd(xmlParserCtxtPtr ctxt, int fd, const char *URL, const char *encoding, int options)
Definition: parser.c:15074
XMLPUBFUN xmlDocPtr xmlReadDoc(const xmlChar *cur, const char *URL, const char *encoding, int options)
Definition: parser.c:14786
XMLPUBFUN void xmlSetExternalEntityLoader(xmlExternalEntityLoader f)
XMLPUBFUN xmlParserInputPtr xmlNewIOInputStream(xmlParserCtxtPtr ctxt, xmlParserInputBufferPtr input, xmlCharEncoding enc)
XMLPUBFUN void xmlStopParser(xmlParserCtxtPtr ctxt)
Definition: parser.c:12311
XML_DEPRECATED XMLPUBFUN int xmlThrDefLineNumbersDefaultValue(int v)
Definition: globals.c:1100
xmlParserNodeInfoSeq * xmlParserNodeInfoSeqPtr
Definition: parser.h:102
void(* endElementNsSAX2Func)(void *ctx, const xmlChar *localname, const xmlChar *prefix, const xmlChar *URI)
Definition: parser.h:729
void(* notationDeclSAXFunc)(void *ctx, const xmlChar *name, const xmlChar *publicId, const xmlChar *systemId)
Definition: parser.h:443
XMLPUBFUN void xmlCtxtReset(xmlParserCtxtPtr ctxt)
Definition: parser.c:14372
void(* referenceSAXFunc)(void *ctx, const xmlChar *name)
Definition: parser.h:559
xmlParserMode
Definition: parser.h:167
@ XML_PARSE_READER
Definition: parser.h:173
@ XML_PARSE_PUSH_SAX
Definition: parser.h:172
@ XML_PARSE_SAX
Definition: parser.h:170
@ XML_PARSE_DOM
Definition: parser.h:169
@ XML_PARSE_PUSH_DOM
Definition: parser.h:171
@ XML_PARSE_UNKNOWN
Definition: parser.h:168
XMLPUBFUN xmlDocPtr xmlReadFile(const char *URL, const char *encoding, int options)
Definition: parser.c:14811
XMLPUBFUN int xmlParseCtxtExternalEntity(xmlParserCtxtPtr ctx, const xmlChar *URL, const xmlChar *ID, xmlNodePtr *lst)
Definition: parser.c:12621
XML_DEPRECATED XMLPUBFUN int xmlParserInputGrow(xmlParserInputPtr in, int len)
void(* externalSubsetSAXFunc)(void *ctx, const xmlChar *name, const xmlChar *ExternalID, const xmlChar *SystemID)
Definition: parser.h:391
xmlParserInputPtr(* xmlExternalEntityLoader)(const char *URL, const char *ID, xmlParserCtxtPtr context)
Definition: parser.h:837
XML_DEPRECATED XMLPUBFUN int xmlLineNumbersDefault(int val)
static int fd
Definition: io.c:51
Definition: dict.c:59
xmlParserMode parseMode
Definition: parser.h:309
int inputMax
Definition: parser.h:209
xmlError lastError
Definition: parser.h:308
unsigned * attallocs
Definition: parser.h:289
char * directory
Definition: parser.h:234
const xmlChar ** atts
Definition: parser.h:271
int nsWellFormed
Definition: parser.h:293
int replaceEntities
Definition: parser.h:197
int hasPErefs
Definition: parser.h:224
xmlValidCtxt vctxt
Definition: parser.h:229
int keepBlanks
Definition: parser.h:244
xmlStartTag * pushTab
Definition: parser.h:290
int external
Definition: parser.h:225
xmlAttrHashBucket * attrHash
Definition: parser.h:329
int spaceMax
Definition: parser.h:254
int wellFormed
Definition: parser.h:196
unsigned attrHashMax
Definition: parser.h:328
int progressive
Definition: parser.h:269
int * space
Definition: parser.h:252
int loadsubset
Definition: parser.h:265
long nbChars
Definition: parser.h:242
int disableSAX
Definition: parser.h:245
const xmlChar * str_xml
Definition: parser.h:278
int freeElemsNr
Definition: parser.h:300
void * _private
Definition: parser.h:263
xmlNodePtr * nodeTab
Definition: parser.h:216
int freeAttrsNr
Definition: parser.h:302
xmlParserInputPtr entity
Definition: parser.h:258
const xmlChar * intSubName
Definition: parser.h:247
xmlChar * extSubSystem
Definition: parser.h:249
struct _xmlSAXHandler * sax
Definition: parser.h:193
xmlParserNodeInfoSeq node_seq
Definition: parser.h:219
int dictNames
Definition: parser.h:299
xmlDocPtr myDoc
Definition: parser.h:195
int hasExternalSubset
Definition: parser.h:223
long checkIndex
Definition: parser.h:243
int pedantic
Definition: parser.h:262
const xmlChar * str_xml_ns
Definition: parser.h:280
xmlParserInputState instate
Definition: parser.h:231
xmlParserNsData * nsdb
Definition: parser.h:327
const xmlChar * str_xmlns
Definition: parser.h:279
unsigned maxAmpl
Definition: parser.h:325
const xmlChar * encoding
Definition: parser.h:199
xmlParserNodeInfo * nodeInfo
Definition: parser.h:314
xmlDictPtr dict
Definition: parser.h:270
int recovery
Definition: parser.h:268
int input_id
Definition: parser.h:319
const xmlChar ** nsTab
Definition: parser.h:288
unsigned short nbWarnings
Definition: parser.h:324
xmlHashTablePtr attsSpecial
Definition: parser.h:292
int nodeInfoMax
Definition: parser.h:316
void * catalogs
Definition: parser.h:267
xmlChar * extSubURI
Definition: parser.h:248
const xmlChar * name
Definition: parser.h:237
unsigned long sizeentities
Definition: parser.h:311
const xmlChar * version
Definition: parser.h:198
xmlAttrPtr freeAttrs
Definition: parser.h:303
int endCheckState
Definition: parser.h:322
unsigned short nbErrors
Definition: parser.h:323
int record_info
Definition: parser.h:218
int * spaceTab
Definition: parser.h:255
int inSubset
Definition: parser.h:246
int standalone
Definition: parser.h:200
unsigned long sizeentcopy
Definition: parser.h:320
xmlParserInputPtr * inputTab
Definition: parser.h:210
const xmlChar ** nameTab
Definition: parser.h:240
void * userData
Definition: parser.h:194
unsigned long nbentities
Definition: parser.h:310
xmlHashTablePtr attsDefault
Definition: parser.h:291
int linenumbers
Definition: parser.h:266
xmlNodePtr node
Definition: parser.h:213
xmlParserNodeInfo * nodeInfoTab
Definition: parser.h:317
int validate
Definition: parser.h:228
xmlNodePtr freeElems
Definition: parser.h:301
xmlParserInputPtr input
Definition: parser.h:207
int nodeInfoNr
Definition: parser.h:315
const char * filename
Definition: parser.h:64
const xmlChar * encoding
Definition: parser.h:74
xmlEntityPtr entity
Definition: parser.h:79
xmlParserInputDeallocate free
Definition: parser.h:73
unsigned long consumed
Definition: parser.h:72
const xmlChar * end
Definition: parser.h:68
const xmlChar * base
Definition: parser.h:66
xmlParserInputBufferPtr buf
Definition: parser.h:62
const xmlChar * version
Definition: parser.h:75
const char * directory
Definition: parser.h:65
unsigned long parentConsumed
Definition: parser.h:78
const xmlChar * cur
Definition: parser.h:67
unsigned long length
Definition: parser.h:105
unsigned long maximum
Definition: parser.h:104
xmlParserNodeInfo * buffer
Definition: parser.h:106
const struct _xmlNode * node
Definition: parser.h:93
unsigned long begin_line
Definition: parser.h:96
unsigned long end_pos
Definition: parser.h:97
unsigned long end_line
Definition: parser.h:98
unsigned long begin_pos
Definition: parser.h:95
commentSAXFunc comment
Definition: parser.h:816
attributeDeclSAXFunc attributeDecl
Definition: parser.h:804
hasExternalSubsetSAXFunc hasExternalSubset
Definition: parser.h:799
ignorableWhitespaceSAXFunc ignorableWhitespace
Definition: parser.h:814
startDocumentSAXFunc startDocument
Definition: parser.h:808
charactersSAXFunc characters
Definition: parser.h:813
endDocumentSAXFunc endDocument
Definition: parser.h:809
processingInstructionSAXFunc processingInstruction
Definition: parser.h:815
startElementSAXFunc startElement
Definition: parser.h:810
elementDeclSAXFunc elementDecl
Definition: parser.h:805
getParameterEntitySAXFunc getParameterEntity
Definition: parser.h:820
internalSubsetSAXFunc internalSubset
Definition: parser.h:796
notationDeclSAXFunc notationDecl
Definition: parser.h:803
isStandaloneSAXFunc isStandalone
Definition: parser.h:797
fatalErrorSAXFunc fatalError
Definition: parser.h:819
getEntitySAXFunc getEntity
Definition: parser.h:801
referenceSAXFunc reference
Definition: parser.h:812
unparsedEntityDeclSAXFunc unparsedEntityDecl
Definition: parser.h:806
errorSAXFunc error
Definition: parser.h:818
resolveEntitySAXFunc resolveEntity
Definition: parser.h:800
cdataBlockSAXFunc cdataBlock
Definition: parser.h:821
endElementSAXFunc endElement
Definition: parser.h:811
entityDeclSAXFunc entityDecl
Definition: parser.h:802
warningSAXFunc warning
Definition: parser.h:817
externalSubsetSAXFunc externalSubset
Definition: parser.h:822
setDocumentLocatorSAXFunc setDocumentLocator
Definition: parser.h:807
unsigned int initialized
Definition: parser.h:823
hasInternalSubsetSAXFunc hasInternalSubset
Definition: parser.h:798
void * _private
Definition: parser.h:784
unparsedEntityDeclSAXFunc unparsedEntityDecl
Definition: parser.h:746
hasExternalSubsetSAXFunc hasExternalSubset
Definition: parser.h:739
setDocumentLocatorSAXFunc setDocumentLocator
Definition: parser.h:747
getEntitySAXFunc getEntity
Definition: parser.h:741
commentSAXFunc comment
Definition: parser.h:769
errorSAXFunc error
Definition: parser.h:771
attributeDeclSAXFunc attributeDecl
Definition: parser.h:744
referenceSAXFunc reference
Definition: parser.h:765
startElementNsSAX2Func startElementNs
Definition: parser.h:785
externalSubsetSAXFunc externalSubset
Definition: parser.h:775
internalSubsetSAXFunc internalSubset
Definition: parser.h:736
endElementSAXFunc endElement
Definition: parser.h:764
isStandaloneSAXFunc isStandalone
Definition: parser.h:737
endDocumentSAXFunc endDocument
Definition: parser.h:749
fatalErrorSAXFunc fatalError
Definition: parser.h:772
hasInternalSubsetSAXFunc hasInternalSubset
Definition: parser.h:738
notationDeclSAXFunc notationDecl
Definition: parser.h:743
resolveEntitySAXFunc resolveEntity
Definition: parser.h:740
getParameterEntitySAXFunc getParameterEntity
Definition: parser.h:773
endElementNsSAX2Func endElementNs
Definition: parser.h:786
cdataBlockSAXFunc cdataBlock
Definition: parser.h:774
startElementSAXFunc startElement
Definition: parser.h:763
xmlStructuredErrorFunc serror
Definition: parser.h:787
entityDeclSAXFunc entityDecl
Definition: parser.h:742
processingInstructionSAXFunc processingInstruction
Definition: parser.h:768
charactersSAXFunc characters
Definition: parser.h:766
warningSAXFunc warning
Definition: parser.h:770
startDocumentSAXFunc startDocument
Definition: parser.h:748
elementDeclSAXFunc elementDecl
Definition: parser.h:745
unsigned int initialized
Definition: parser.h:780
ignorableWhitespaceSAXFunc ignorableWhitespace
Definition: parser.h:767
int(* getColumnNumber)(void *ctx)
Definition: parser.h:341
int(* getLineNumber)(void *ctx)
Definition: parser.h:340
Definition: http.c:7252
Definition: name.c:39
Definition: tools.h:99
Character const *const prefix
Definition: tempnam.cpp:195
Definition: dlist.c:348
Definition: pdh_main.c:96
typedeftypedef void(*) typedef void(*) struct _xmlValidCtx xmlValidCtxt)
Definition: valid.h:67
int(* xmlInputReadCallback)(void *context, char *buffer, int len)
Definition: xmlIO.h:58
int(* xmlInputCloseCallback)(void *context)
Definition: xmlIO.h:67
void(*) typedef void(* xmlStructuredErrorFunc)(void *userData, const xmlError *error)
Definition: xmlerror.h:859
xmlParserErrors
Definition: xmlerror.h:99
#define XMLPUBFUN
Definition: xmlexports.h:30
#define XMLPUBVAR
Definition: xmlexports.h:37
unsigned char xmlChar
Definition: xmlstring.h:28
#define LIBXML_ATTR_FORMAT(fmt, args)
Definition: xmlversion.h:472
#define XML_DEPRECATED
Definition: xmlversion.h:475