Lines Matching full:code
62 <code>XML::Parser</code>, Python's <code>xml.parsers.expat</code>, and
209 <dt><code><a href= "#XML_ParserCreate"
210 >XML_ParserCreate</a></code></dt>
213 <dt><code><a href= "#XML_SetElementHandler"
214 >XML_SetElementHandler</a></code></dt>
217 <dt><code><a href= "#XML_SetCharacterDataHandler"
218 >XML_SetCharacterDataHandler</a></code></dt>
221 <dt><code><a href= "#XML_Parse"
222 >XML_Parse</a></code></dt>
238 information. Finally it increments the global <code>Depth</code>
263 <code>Depth</code>.</p>
271 <p>Note the <code>XMLCALL</code> annotation used for the callbacks.
274 itself and the client code are different. Expat tries not to care
277 For code which uses Expat, however, the calling convention is
278 specified by the <code>XMLCALL</code> annotation on most platforms;
281 <p>The <code>XMLCALL</code> annotation was added in Expat 1.95.7, but
320 you can use CMake to generate a <code>.sln</code> file, e.g.
321 <code>
323 </code>, and build Expat using <code>msbuild /m expat.sln</code> after.</p>
344 only one we'll mention here is the <code>--prefix</code> option. You
346 the <code>--help</code> option.</p>
349 gets installed in <code>/usr/local/lib</code> and the associated
350 header file in <code>/usr/local/include</code>. But if you were to
351 give the option, <code>--prefix=/home/me/mystuff</code>, then the
353 <code>/home/me/mystuff/lib</code> and
354 <code>/home/me/mystuff/include</code> respectively.</p>
367 (syntax <code>&e1;</code> to reference and
368 syntax <code><!ENTITY e1 'value1'></code> (an internal general entity) or
369 <code><!ENTITY e2 SYSTEM 'file2'></code> (an external general entity) to declare).
370 With <code>XML_GE</code> enabled, general entities will be replaced by their declared replacement t…
372 <code><a href="#XML_SetExternalEntityRefHandler">XML_ExternalEntityRefHandler</a></code> must be se…
373 <code><a href="#XML_SetExternalEntityRefHandler">XML_SetExternalEntityRefHandler</a></code>.
374 Also, enabling <code>XML_GE</code> makes
375 the functions <code><a href="#XML_SetBillionLaughsAttackProtectionMaximumAmplification">
376 XML_SetBillionLaughsAttackProtectionMaximumAmplification</a></code> and <code>
378 XML_SetBillionLaughsAttackProtectionActivationThreshold</a></code> available.
380 With <code>XML_GE</code> disabled, Expat has a smaller memory footprint and can be faster, but will
383 <code>amp</code>, <code>apos</code>, <code>gt</code>, <code>lt</code>, <code>quot</code>)
385 for example, referencing an entity <code>e1</code> via <code>&e1;</code> will be replaced
386 by text <code>&e1;</code>.
396 the functions <code><a
398 XML_SetBillionLaughsAttackProtectionMaximumAmplification</a></code> and <code>
400 XML_SetBillionLaughsAttackProtectionActivationThreshold</a></code> available.</dd>
410 <code>XML_Char</code>. This is implied if
411 <code>XML_UNICODE_WCHAR_T</code> is defined.</dd>
414 <dd>If defined, causes the <code>XML_Char</code> character type to be
415 defined using the <code>wchar_t</code> type; otherwise, <code>unsigned
416 short</code> is used. Defining this implies
417 <code>XML_UNICODE</code>.</dd>
420 <dd>If defined, causes the <code>XML_Size</code> and <code>XML_Index</code>
423 <code><a href="#XML_GetCurrentByteIndex" >XML_GetCurrentByteIndex</a></code>,
424 <code><a href="#XML_GetCurrentLineNumber" >XML_GetCurrentLineNumber</a></code> and
425 <code><a href="#XML_GetCurrentColumnNumber" >XML_GetCurrentColumnNumber</a></code>
431 ensure are available for reporting via <code><a href=
432 "#XML_GetInputContext" >XML_GetInputContext</a></code>. This is
434 If this is set to zero, the input context will not be available and <code><a
435 href= "#XML_GetInputContext" >XML_GetInputContext</a></code> will
436 always report <code>NULL</code>. Without this, Expat has a smaller memory
441 statically with the code that calls it; this is required to get all
446 <dd>If defined, makes the additional function <code><a href=
447 "#XML_GetAttributeInfo" >XML_GetAttributeInfo</a></code> available
458 is to include the Expat header (<code>#include <expat.h></code>)
461 usually be done with the <code>-lexpat</code> argument. Otherwise,
478 <p>If you installed Expat in, say, <code>/home/me/mystuff</code>, then
491 <code>LD_LIBRARY_PATH</code> to <code>/home/me/mystuff/lib</code> (or
492 to <code>${LD_LIBRARY_PATH}:/home/me/mystuff/lib</code> if
501 parser object. However, only two of these (<code><a href=
502 "#XML_ParserCreate" >XML_ParserCreate</a></code> and <code><a href=
503 "#XML_ParserCreateNS" >XML_ParserCreateNS</a></code>) can be used for
507 memory associated with this object you must call <code><a href=
508 "#XML_ParserFree" >XML_ParserFree</a></code>. Note that if you have
511 calling <code>XML_ParserFree</code>.</p>
584 incremented depth <em>after</em> the main body of start tag code, then
594 the shared variables. You can then tell Expat (with the <code><a href=
595 "#XML_SetUserData" >XML_SetUserData</a></code> function) to pass a
599 <code>userData</code> and have type <code>void *</code> if the user
600 data is passed; it will have the type <code>XML_Parser</code> if the
602 be retrieved using <code><a href="#XML_GetUserData"
603 >XML_GetUserData</a></code>.</p>
607 content passed to the character data handler (set by <code><a href=
609 >XML_SetCharacterDataHandler</a></code>) needs to be accumulated. A
625 the value of the <code>version</code> pseudo-attribute in the XML
629 alternate processing), it should use the <code><a href=
630 "#XML_SetXmlDeclHandler" >XML_SetXmlDeclHandler</a></code> function to
633 version number of <code>"1.0"</code> is accepted:</p>
664 <p>When the parser is created using the <code><a href=
665 "#XML_ParserCreateNS" >XML_ParserCreateNS</a></code>, function, Expat
667 consumes <code>xmlns</code> and <code>xmlns:...</code> attributes,
673 ><code>XML_SetNamespaceDeclHandler</code></a>.</p>
678 separator character (which is the 2nd argument to <code><a href=
679 "#XML_ParserCreateNS" >XML_ParserCreateNS</a></code>), and the local
686 <p>However if <code><a href= "#XML_SetReturnNSTriplet"
687 >XML_SetReturnNSTriplet</a></code> has been called with a non-zero
688 <code>do_nst</code> parameter, then the expanded form for names with
693 for the end of a scope of a declaration with the <code><a href=
694 "#XML_SetNamespaceDeclHandler" >XML_SetNamespaceDeclHandler</a></code>
700 <code>NULL</code>.
701 The URI will be <code>NULL</code> for the case where the default namespace is being
743 to the <code>UnknownEncodingHandler</code>. This handler gets passed
744 the encoding name and a pointer to an <code>XML_Encoding</code> data
746 <code>XML_STATUS_OK</code> if it knows how to deal with the
748 <code>XML_STATUS_ERROR</code>. The handler also gets passed a pointer
753 support by filling in the <code>XML_Encoding</code> structure.
767 <p><code>XML_Encoding</code> contains an array of integers that
774 function pointed at in the <code>XML_Encoding</code> structure. This
788 set no <code>ExternalEntityRefHandler</code>, then external entity
793 it is responsible for creating a subsidiary parser with <code><a href=
795 >XML_ExternalEntityParserCreate</a></code> that will do the job. This
796 returns an instance of <code>XML_Parser</code> that has handlers and
798 use <code><a href= "#XML_Parse" >XML_Parse</a></code> or <code><a
799 href= "#XML_ParseBuffer">XML_ParseBuffer</a></code> calls against this
806 you must call <code><a href= "#XML_SetParamEntityParsing"
807 >XML_SetParamEntityParsing</a></code> with one of the following
810 <dt><code>XML_PARAM_ENTITY_PARSING_NEVER</code></dt>
812 <dt><code>XML_PARAM_ENTITY_PARSING_UNLESS_STANDALONE</code></dt>
814 <code>standalone</code> was set to "yes" in the XML declaration.</dd>
815 <dt><code>XML_PARAM_ENTITY_PARSING_ALWAYS</code></dt>
853 the rough structure (in pseudo-code):</p>
877 <p>This C function could be used for the <code>parse_xml</code>
878 function mentioned in the pseudo-code above:</p>
920 <p>The corresponding <code>continue_parsing</code> function is
921 somewhat simpler, since it only need deal with the return code from
922 <code><a href= "#XML_ResumeParser">XML_ResumeParser</a></code>; it can
923 delegate the input handling to the <code>parse_xml</code>
950 become, what have we gained? Very simply, we can now use the <code><a
951 href= "#XML_StopParser" >XML_StopParser</a></code> function to stop
957 <p>To stop parsing from a handler function, use the <code><a href=
958 "#XML_StopParser" >XML_StopParser</a></code> function. This function
979 Construct a new parser. If encoding is non-<code>NULL</code>, it specifies a
1007 in XML. For instance, <code>'\xFF'</code> is not legal in UTF-8, and
1008 <code>'\xFFFF'</code> is not legal in UTF-16. There is a special case when
1009 <em>sep</em> is the null character <code>'\0'</code>: the namespace URI and
1038 specified in <code>ms</code>. If <code>ms</code> is <code>NULL</code>, then use the
1039 standard set of memory management functions. If <code>sep</code> is
1040 non-<code>NULL</code>, then namespace processing is enabled in the created parser
1053 Construct a new <code>XML_Parser</code> object for parsing an external
1080 be used again. After this has been called, <code>parser</code> is
1084 This function may not be used on a parser created using <code><a href=
1086 ></code>; it will return <code>XML_FALSE</code> in that case. Returns
1087 <code>XML_TRUE</code> on success. Your application is responsible for
1093 <p>To state the obvious: the three parsing functions <code><a href=
1094 "#XML_Parse" >XML_Parse</a></code>, <code><a href= "#XML_ParseBuffer">
1095 XML_ParseBuffer</a></code> and <code><a href= "#XML_GetBuffer">
1096 XML_GetBuffer</a></code> must not be called from within a handler
1099 functions from within an <code>XML_ExternalEntityRefHandler</code>,
1101 <code><a href= "#XML_ExternalEntityParserCreate"
1102 >XML_ExternalEntityParserCreate</a></code>.</p>
1104 <p>Note: The <code>len</code> argument passed to these functions
1113 <code><a href="#XML_Parse">XML_Parse</a></code> or
1114 <code><a href="#XML_ParseBuffer">XML_ParseBuffer</a></code> call
1115 with <code>isFinal</code> set to <code>XML_TRUE</code>.</p>
1133 Parse some more of the document. The string <code>s</code> is a buffer
1135 that are part of the document is indicated by <code>len</code>. This means
1136 that <code>s</code> doesn't have to be null-terminated. It also means that
1137 if <code>len</code> is larger than the number of bytes in the block of
1138 memory that <code>s</code> points at, then a memory fault is likely.
1139 Negative values for <code>len</code> are rejected since Expat 2.2.1.
1141 <code>isFinal</code> parameter informs the parser that this is the last
1143 <code>len</code> is zero.)
1147 If a parse error occurred, it returns <code>XML_STATUS_ERROR</code>.
1148 Otherwise it returns <code>XML_STATUS_OK</code> value.
1156 Simplified, <code>XML_Parse</code> can be considered a convenience wrapper
1158 to <code><a href="#XML_GetBuffer">XML_GetBuffer</a></code>
1159 and <code><a href="#XML_ParseBuffer">XML_ParseBuffer</a></code>
1160 (when Expat is built with macro <code>XML_CONTEXT_BYTES</code>
1162 <code>XML_Parse</code> is then functionally equivalent to calling
1163 <code><a href="#XML_GetBuffer">XML_GetBuffer</a></code>,
1164 <code>memcpy</code>, and
1165 <code><a href="#XML_ParseBuffer">XML_ParseBuffer</a></code>.
1170 <code><a href="#XML_GetBuffer">XML_GetBuffer</a></code> and
1171 <code><a href="#XML_ParseBuffer">XML_ParseBuffer</a></code> is advised
1173 if you're using <code>read</code> or similar functionality to fill your
1175 <code><a href="#XML_GetBuffer">XML_GetBuffer</a></code>,
1176 then parse with <code><a href="#XML_ParseBuffer">XML_ParseBuffer</a></code>.
1189 This is just like <code><a href= "#XML_Parse" >XML_Parse</a></code>,
1191 buffer from Expat with the <code><a href= "#XML_GetBuffer"
1192 >XML_GetBuffer</a></code> function, the application can avoid double
1197 Negative values for <code>len</code> are rejected since Expat 2.6.3.
1208 Obtain a buffer of size <code>len</code> to read a piece of the document
1209 into. A <code>NULL</code> value is returned if Expat can't allocate enough memory for
1210 this buffer. A <code>NULL</code> value may also be returned if <code>len</code> is zero.
1212 <code><a href= "#XML_ParseBuffer" >XML_ParseBuffer</a></code>. A
1246 <p>Stops parsing, causing <code><a href= "#XML_Parse"
1247 >XML_Parse</a></code> or <code><a href= "#XML_ParseBuffer"
1248 >XML_ParseBuffer</a></code> to return. Must be called from within a
1249 call-back handler, except when aborting (when <code>resumable</code>
1250 is <code>XML_FALSE</code>) an already suspended parser. Some
1265 <code>resumable</code> is <code>XML_TRUE</code>. Returns
1266 <code>XML_STATUS_OK</code> when successful,
1267 <code>XML_STATUS_ERROR</code> otherwise. The possible error codes
1270 <dt><code>XML_ERROR_NOT_STARTED</code></dt>
1275 <dt><code>XML_ERROR_SUSPENDED</code></dt>
1277 <dt><code>XML_ERROR_FINISHED</code></dt>
1279 <dt><code>XML_ERROR_SUSPEND_PE</code></dt>
1288 <p>When <code>resumable</code> is <code>XML_TRUE</code> then parsing
1289 is <em>suspended</em>, that is, <code><a href= "#XML_Parse"
1290 >XML_Parse</a></code> and <code><a href= "#XML_ParseBuffer"
1291 >XML_ParseBuffer</a></code> return <code>XML_STATUS_SUSPENDED</code>.
1292 Otherwise, parsing is <em>aborted</em>, that is, <code><a href=
1293 "#XML_Parse" >XML_Parse</a></code> and <code><a href=
1294 "#XML_ParseBuffer" >XML_ParseBuffer</a></code> return
1295 <code>XML_STATUS_ERROR</code> with error code
1296 <code>XML_ERROR_ABORTED</code>.</p>
1302 implementation of that handler to call <code><a href=
1303 "#XML_StopParser" >XML_StopParser</a></code> on the parent parser
1306 <p>When suspended, parsing can be resumed by calling <code><a href=
1307 "#XML_ResumeParser" >XML_ResumeParser</a></code>.</p>
1318 <p>Resumes parsing after it has been suspended with <code><a href=
1319 "#XML_StopParser" >XML_StopParser</a></code>. Must not be called from
1320 within a handler call-back. Returns same status codes as <code><a
1321 href= "#XML_Parse">XML_Parse</a></code> or <code><a href=
1322 "#XML_ParseBuffer" >XML_ParseBuffer</a></code>. An additional error
1323 code, <code>XML_ERROR_NOT_SUSPENDED</code>, will be returned if the
1331 and it is up to the application to call <code><a href=
1332 "#XML_ResumeParser" >XML_ResumeParser</a></code> on it at the
1360 processed. The <code>status</code> parameter <em>must not</em> be
1361 <code>NULL</code>.</p>
1372 to ignore all text not descended from a <code>para</code> element. One
1376 <p>A handler may be <em>unset</em> by providing a <code>NULL</code> pointer to the
1381 <code>XML_Char</code>. This type is conditionally defined in expat.h as
1382 either <code>char</code>, <code>wchar_t</code> or <code>unsigned short</code>.
1404 by a <code>NULL</code> pointer.</p>
1454 be split across calls to this handler. Note: Setting this handler to <code>NULL</code>
1562 <p>See also <code><a
1563 href="#XML_DefaultCurrent">XML_DefaultCurrent</a></code>.</p>
1583 <p>See also <code><a
1584 href="#XML_DefaultCurrent">XML_DefaultCurrent</a></code>.</p>
1605 <code>XML_SetParamEntityParsing</code></a>.)</p>
1607 <p>The <code>context</code> parameter specifies the parsing context in
1608 the format expected by the <code>context</code> argument to <code><a
1610 >XML_ExternalEntityParserCreate</a></code>. <code>code</code> is
1612 to be parsed later, it must be copied. <code>context</code> is <code>NULL</code>
1616 <p>The <code>base</code> parameter is the base to use for relative
1617 system identifiers. It is set by <code><a
1618 href="#XML_SetBase">XML_SetBase</a></code> and may be <code>NULL</code>. The
1619 <code>publicId</code> parameter is the public id given in the entity
1620 declaration and may be <code>NULL</code>. <code>systemId</code> is the system
1621 identifier specified in the entity declaration and is never <code>NULL</code>.</p>
1625 integer). <code>XML_STATUS_OK</code> should be returned for successful
1627 <code>XML_STATUS_ERROR</code> indicates failure, and causes the
1629 <code>XML_ERROR_EXTERNAL_ENTITY_HANDLING</code> error.</p>
1634 <code><a href= "#XML_ExternalEntityParserCreate"
1635 >XML_ExternalEntityParserCreate</a></code>. Using the returned
1650 <code>arg</code> is not <code>NULL</code>, it is the new value passed to the
1651 handler set using <code><a href="#XML_SetExternalEntityRefHandler"
1652 >XML_SetExternalEntityRefHandler</a></code>; if <code>arg</code> is
1653 <code>NULL</code>, the argument passed to the handler function will be the parser
1657 The type of <code>arg</code> and the type of the first argument to the
1659 <code>void *</code> to be passed to the handler, while the handler
1660 accepts an <code>XML_Parser</code>. This is a historical accident,
1662 causing compiler warnings for code that's known to work with this
1663 API. It is the responsibility of the application code to know the
1686 <a href="#XML_SetDefaultHandler"><code>XML_SetDefaultHandler</code></a>
1689 <p>The <code>is_parameter_entity</code> argument will be non-zero for
1719 <code><a href= "#XML_Parse" >XML_Parse</a></code> or <code><a href=
1720 "#XML_ParseBuffer" >XML_ParseBuffer</a></code> have been called on the
1722 with the given name, it should fill in the <code>info</code> data
1723 structure and return <code>XML_STATUS_OK</code>. Otherwise it
1724 should return <code>XML_STATUS_ERROR</code>. The handler will be called
1726 data pointer <code>encodingHandlerData</code> will be passed back to
1736 if the sequence itself is invalid. The convert pointer may be <code>NULL</code> if
1738 function is the data pointer from <code>XML_Encoding</code>. The
1742 <p>The function pointed at by <code>release</code> is called by the
1743 parser when it is finished with the encoding. It may be <code>NULL</code>.</p>
1810 distinguish is that the <code>version</code> parameter will be <code>NULL</code>
1811 for text declarations. The <code>encoding</code> parameter may be <code>NULL</code>
1812 for an XML declaration. The <code>standalone</code> argument will
1834 before any external or internal subset is parsed. Both <code>sysid</code>
1835 and <code>pubid</code> may be <code>NULL</code>. The <code>has_internal_subset</code>
1907 to a structure that contains the element model. It's the user code's
1908 responsibility to free model when finished with it. See <code>
1909 <a href="#XML_FreeContentModel">XML_FreeContentModel</a></code>.
1913 <p>The <code>model</code> argument is the root of a tree of
1914 <code>XML_Content</code> nodes. If <code>type</code> equals
1915 <code>XML_CTYPE_EMPTY</code> or <code>XML_CTYPE_ANY</code>, then
1916 <code>quant</code> will be <code>XML_CQUANT_NONE</code>, and the other
1917 fields will be zero or <code>NULL</code>. If <code>type</code> is
1918 <code>XML_CTYPE_MIXED</code>, then <code>quant</code> will be
1919 <code>XML_CQUANT_NONE</code> or <code>XML_CQUANT_REP</code> and
1920 <code>numchildren</code> will contain the number of elements that are
1921 allowed to be mixed in and <code>children</code> points to an array of
1922 <code>XML_Content</code> structures that will all have type
1924 <code>XML_CTYPE_EMPTY</code>, <code>XML_CTYPE_ANY</code>, or
1925 <code>XML_CTYPE_MIXED</code>.</p>
1927 <p>For type <code>XML_CTYPE_NAME</code>, the <code>name</code> field
1928 points to the name and the <code>numchildren</code> and
1929 <code>children</code> fields will be zero and <code>NULL</code>. The
1930 <code>quant</code> field will indicate any quantifiers placed on the
1933 <p>Types <code>XML_CTYPE_CHOICE</code> and <code>XML_CTYPE_SEQ</code>
1935 <code>numchildren</code> field indicates how many nodes in the choice
1936 or sequence and <code>children</code> points to the nodes.</p>
1958 handler. The <code>elname</code> parameter returns the name of the
1960 is in the <code>attname</code> parameter. The attribute type is in the
1961 <code>att_type</code> parameter. It is the string representing the
1964 <p>The <code>dflt</code> parameter holds the default value. It will be
1965 <code>NULL</code> in the case of "#IMPLIED" or "#REQUIRED" attributes. You can
1966 distinguish these two cases by checking the <code>isrequired</code>
1969 <code>isrequired</code>, but they will have the non-<code>NULL</code> fixed value
1970 in the <code>dflt</code> parameter.</p>
1993 The <code>is_parameter_entity</code> argument will be non-zero in the
1996 <p>For internal entities (<code><!ENTITY foo "bar"></code>),
1997 <code>value</code> will be non-<code>NULL</code> and <code>systemId</code>,
1998 <code>publicId</code>, and <code>notationName</code> will all be <code>NULL</code>.
2000 provided in the <code>value_length</code> parameter. Do not use
2001 <code>value_length</code> to test for internal entities, since it is
2003 <code>value</code> is <code>NULL</code>.</p> <p>The <code>notationName</code>
2004 argument will have a non-<code>NULL</code> value only for unparsed entity
2067 declaration. If this handler returns <code>XML_STATUS_ERROR</code>,
2068 then the parser will throw an <code>XML_ERROR_NOT_STANDALONE</code>
2075 functions return <code>XML_STATUS_ERROR</code> (a parse error has
2080 the parse functions to return <code>XML_STATUS_ERROR</code>.) The
2102 XML_ErrorString(enum XML_Error code);
2105 Return a string describing the error corresponding to code.
2106 The code should be one of the enums that can be returned from
2107 <code><a href= "#XML_GetErrorCode" >XML_GetErrorCode</a></code>.
2117 the values returned by <code><a href= "#XML_GetCurrentLineNumber"
2118 >XML_GetCurrentLineNumber</a></code> and <code><a href=
2119 "#XML_GetCurrentColumnNumber" >XML_GetCurrentColumnNumber</a></code>.
2129 <code>1</code>.
2149 <code>0</code> if the event is inside a reference to an internal
2165 <code>offset</code> to the offset within this buffer of the current
2166 parse position, and set the integer pointed at by <code>size</code> to
2178 <p>If <code>XML_CONTEXT_BYTES</code> is zero, this will always
2179 return <code>NULL</code>.</p>
2196 (default: <code>100.0</code>)
2197 of parser <code>p</code> to <code>maximumAmplificationFactor</code>, and
2198 returns <code>XML_TRUE</code> upon success and <code>XML_FALSE</code> upon error.
2206 <code>direct</code> is the number of bytes read from the primary document in parsing and
2207 …<code>indirect</code> is the number of bytes added by expanding entities and reading of external D…
2209 …<p>For a call to <code>XML_SetBillionLaughsAttackProtectionMaximumAmplification</code> to succeed:…
2211 …<li>parser <code>p</code> must be a non-<code>NULL</code> root parser (without any parent parsers)…
2212 …<li><code>maximumAmplificationFactor</code> must be non-<code>NaN</code> and greater than or equal…
2246 (default: <code>8 MiB</code>)
2247 of parser <code>p</code> to <code>activationThresholdBytes</code>, and
2248 returns <code>XML_TRUE</code> upon success and <code>XML_FALSE</code> upon error.
2251 …<p>For a call to <code>XML_SetBillionLaughsAttackProtectionActivationThreshold</code> to succeed:<…
2253 …<li>parser <code>p</code> must be a non-<code>NULL</code> root parser (without any parent parsers)…
2284 The <code>enabled</code> argument should be <code>XML_TRUE</code> or <code>XML_FALSE</code>.
2287 Returns <code>XML_TRUE</code> on success, and <code>XML_FALSE</code> on error.
2306 <code>userData</code> when it is finished with the parser. So if you
2329 <code>userData</code> arguments. The user data can still be obtained
2330 using the <code><a href= "#XML_GetUserData"
2331 >XML_GetUserData</a></code> function.
2342 identifiers. The return value is <code>XML_STATUS_ERROR</code> if
2344 <code>XML_STATUS_OK</code>.
2367 <code>atts</code> array passed to the start tag handler of the first
2380 last call to <code><a href= "#XML_StartElementHandler"
2381 >XML_StartElementHandler</a></code>, or -1 if there is no ID
2400 Returns an array of <code>XML_AttrInfo</code> structures for the
2402 <code>XML_StartElementHandler</code> that were specified
2405 <code>XML_GetSpecifiedAttributeCount(parser) / 2</code>.
2416 passing a non-<code>NULL</code> encoding argument to the parser creation functions.
2417 It must not be called after <code><a href= "#XML_Parse"
2418 >XML_Parse</a></code> or <code><a href= "#XML_ParseBuffer"
2419 >XML_ParseBuffer</a></code> have been called on the given parser.
2420 Returns <code>XML_STATUS_OK</code> on success or
2421 <code>XML_STATUS_ERROR</code> on error.
2428 enum XML_ParamEntityParsing code);
2433 <code>code</code>.
2434 The choices for <code>code</code> are:
2436 <li><code>XML_PARAM_ENTITY_PARSING_NEVER</code></li>
2437 <li><code>XML_PARAM_ENTITY_PARSING_UNLESS_STANDALONE</code></li>
2438 <li><code>XML_PARAM_ENTITY_PARSING_ALWAYS</code></li>
2440 <b>Note:</b> If <code>XML_SetParamEntityParsing</code> is called after
2441 <code>XML_Parse</code> or <code>XML_ParseBuffer</code>, then it has
2456 after <code>XML_Parse</code> or <code>XML_ParseBuffer</code>.
2459 <p><b>Note:</b> One should not call <code>XML_SetHashSalt</code> with a
2461 that <code>XML_SetHashSalt</code> has <b>not</b> been called. Consequently
2476 declaration at all and <code>useDTD</code> is true, the
2478 <code>startDoctypeDeclHandler</code> and
2479 <code>endDoctypeDeclHandler</code> functions, if set, will not be
2481 <code><a href= "#XML_SetParamEntityParsing"
2482 >XML_SetParamEntityParsing</a></code>, will be honored.</p>
2485 external entity reference handler set via <code><a href=
2487 >XML_SetExternalEntityRefHandler</a></code> with both
2488 <code>publicId</code> and <code>systemId</code> set to <code>NULL</code>.</p>
2491 <code>XML_ERROR_CANT_CHANGE_FEATURE_ONCE_PARSING</code> and ignores
2492 <code>useDTD</code>. If called when Expat has been compiled without
2494 <code>XML_ERROR_FEATURE_REQUIRES_XML_DTD</code>. Otherwise, it
2495 returns <code>XML_ERROR_NONE</code>.</p>
2498 <code>useDTD == XML_TRUE</code> will make the parser behave as if
2512 <code><a href= "#XML_ParserCreateNS" >XML_ParserCreateNS</a></code>,
2513 i.e. when namespace processing is in effect. The <code>do_nst</code>
2515 namespace prefix. If this function is called with <code>do_nst</code>
2521 <code>do_nst</code> is zero, then namespaces are reported in the
2534 markup to be passed to the default handler set by <code><a
2535 href="#XML_SetDefaultHandler" >XML_SetDefaultHandler</a></code> or
2536 <code><a href="#XML_SetDefaultHandlerExpand"
2537 >XML_SetDefaultHandlerExpand</a></code>. It does nothing if there is
2547 Return the library version as a string (e.g. <code>"expat_1.95.1"</code>).
2567 <li><code>XML_MAJOR_VERSION</code></li>
2568 <li><code>XML_MINOR_VERSION</code></li>
2569 <li><code>XML_MICRO_VERSION</code></li>
2604 available from Expat. This function allows code that does need to
2607 <p>The return value is an array of <code>XML_Feature</code>,
2608 terminated by a record with a <code>feature</code> of
2609 <code>XML_FEATURE_END</code> and <code>name</code> of <code>NULL</code>,
2612 the type of character the <code>name</code> points to, records for the
2613 <code>XML_FEATURE_SIZEOF_XML_CHAR</code> and
2614 <code>XML_FEATURE_SIZEOF_XML_LCHAR</code> will be located at the
2615 beginning of the list, followed by <code>XML_FEATURE_UNICODE</code>
2616 and <code>XML_FEATURE_UNICODE_WCHAR_T</code>, if they are present at
2620 associated value, the <code>value</code> field is set to 0. At this
2624 <dt><code>XML_FEATURE_SIZEOF_XML_CHAR</code></dt>
2625 <dd>The number of bytes occupied by one <code>XML_Char</code>
2627 <dt><code>XML_FEATURE_SIZEOF_XML_LCHAR</code></dt>
2628 <dd>The number of bytes occupied by one <code>XML_LChar</code>
2630 <dt><code>XML_FEATURE_CONTEXT_BYTES</code></dt>
2632 reported by <code><a href= "#XML_GetInputContext"
2633 >XML_GetInputContext</a></code>.</dd>
2643 Function to deallocate the <code>model</code> argument passed to the
2644 <code>XML_ElementDeclHandler</code> callback set using <code><a
2645 href="#XML_SetElementDeclHandler" >XML_ElementDeclHandler</a></code>.
2649 <p>The following functions allow external code to share the memory
2650 allocator an <code>XML_Parser</code> has been configured to use. This
2652 parser object created by application code, or heavily layered
2663 Allocate <code>size</code> bytes of memory using the allocator the
2664 <code>parser</code> object has been configured to use. Returns a
2665 pointer to the memory or <code>NULL</code> on failure. Memory allocated in this
2666 way must be freed using <code><a href="#XML_MemFree"
2667 >XML_MemFree</a></code>.
2676 Allocate <code>size</code> bytes of memory using the allocator the
2677 <code>parser</code> object has been configured to use.
2678 <code>ptr</code> must point to a block of memory allocated by <code><a
2679 href="#XML_MemMalloc" >XML_MemMalloc</a></code> or
2680 <code>XML_MemRealloc</code>, or be <code>NULL</code>. This function tries to
2681 expand the block pointed to by <code>ptr</code> if possible. Returns
2682 a pointer to the memory or <code>NULL</code> on failure. On success, the original
2686 <code><a href="#XML_MemFree"
2687 >XML_MemFree</a></code>.
2696 Free a block of memory pointed to by <code>ptr</code>. The block must
2697 have been allocated by <code><a href="#XML_MemMalloc"
2698 >XML_MemMalloc</a></code> or <code>XML_MemRealloc</code>, or be <code>NULL</code>.