You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1017 lines
111 KiB

  1. <HTML><HEAD><META content="text/html; charset=utf8" http-equiv="Content-Type"><SCRIPT language="JavaScript" src="resources/script.js" type="text/javascript"></SCRIPT><TITLE>SAX2 Programming Guide</TITLE></HEAD><BODY alink="#ff0000" bgcolor="#ffffff" leftmargin="4" link="#0000ff" marginheight="4" marginwidth="4" text="#000000" topmargin="4" vlink="#0000aa"><TABLE border="0" cellpadding="0" cellspacing="0" width="620"><TR><TD align="left" height="60" rowspan="3" valign="top" width="135"><IMG border="0" height="60" hspace="0" src="resources/logo.gif" vspace="0" width="135"></TD><TD align="left" colspan="4" height="5" valign="top" width="456"><IMG border="0" height="5" hspace="0" src="resources/line.gif" vspace="0" width="456"></TD><TD align="left" height="60" rowspan="3" valign="top" width="29"><IMG border="0" height="60" hspace="0" src="resources/right.gif" vspace="0" width="29"></TD></TR><TR><TD align="left" bgcolor="#0086b2" colspan="4" height="35" valign="top" width="456"><IMG alt="" border="0" height="35" hspace="0" src="graphics/program-sax2-3-header.jpg" vspace="0" width="456"></TD></TR><TR><TD align="left" height="20" valign="top" width="168"><IMG border="0" height="20" hspace="0" src="resources/bottom.gif" vspace="0" width="168"></TD><TD align="left" height="20" valign="top" width="96"><A href="http://xml.apache.org/" onMouseOut="rolloverOff('xml');" onMouseOver="rolloverOn('xml');" target="new"><IMG alt="http://xml.apache.org/" border="0" height="20" hspace="0" name="xml" onLoad="rolloverLoad('xml','resources/button-xml-hi.gif','resources/button-xml-lo.gif');" src="resources/button-xml-lo.gif" vspace="0" width="96"></A></TD><TD align="left" height="20" valign="top" width="96"><A href="http://www.apache.org/" onMouseOut="rolloverOff('asf');" onMouseOver="rolloverOn('asf');" target="new"><IMG alt="http://www.apache.org/" border="0" height="20" hspace="0" name="asf" onLoad="rolloverLoad('asf','resources/button-asf-hi.gif','resources/button-asf-lo.gif');" src="resources/button-asf-lo.gif" vspace="0" width="96"></A></TD><TD align="left" height="20" valign="top" width="96"><A href="http://www.w3.org/" onMouseOut="rolloverOff('w3c');" onMouseOver="rolloverOn('w3c');" target="new"><IMG alt="http://www.w3.org/" border="0" height="20" hspace="0" name="w3c" onLoad="rolloverLoad('w3c','resources/button-w3c-hi.gif','resources/button-w3c-lo.gif');" src="resources/button-w3c-lo.gif" vspace="0" width="96"></A></TD></TR></TABLE><TABLE border="0" cellpadding="0" cellspacing="0" width="620"><TR><TD align="left" valign="top" width="120"><IMG border="0" height="14" hspace="0" src="resources/join.gif" vspace="0" width="120"><BR>
  2. <A href="../index.html" onMouseOut="rolloverOff('side-ext-2');" onMouseOver="rolloverOn('side-ext-2');"><IMG alt="Xerces Project" border="0" height="12" hspace="0" name="side-ext-2" onLoad="rolloverLoad('side-ext-2','graphics/ext-2-label-2.jpg','graphics/ext-2-label-3.jpg');" src="graphics/ext-2-label-3.jpg" vspace="0" width="120"></A><BR>
  3. <IMG border="0" height="6" hspace="0" src="resources/separator.gif" vspace="0" width="120"><BR>
  4. <A href="index.html" onMouseOut="rolloverOff('side-index');" onMouseOver="rolloverOn('side-index');"><IMG alt="Overview" border="0" height="12" hspace="0" name="side-index" onLoad="rolloverLoad('side-index','graphics/index-label-2.jpg','graphics/index-label-3.jpg');" src="graphics/index-label-3.jpg" vspace="0" width="120"></A><BR>
  5. <A href="charter.html" onMouseOut="rolloverOff('side-charter');" onMouseOver="rolloverOn('side-charter');"><IMG alt="Charter" border="0" height="12" hspace="0" name="side-charter" onLoad="rolloverLoad('side-charter','graphics/charter-label-2.jpg','graphics/charter-label-3.jpg');" src="graphics/charter-label-3.jpg" vspace="0" width="120"></A><BR>
  6. <A href="releases.html" onMouseOut="rolloverOff('side-releases');" onMouseOver="rolloverOn('side-releases');"><IMG alt="Release Info" border="0" height="12" hspace="0" name="side-releases" onLoad="rolloverLoad('side-releases','graphics/releases-label-2.jpg','graphics/releases-label-3.jpg');" src="graphics/releases-label-3.jpg" vspace="0" width="120"></A><BR>
  7. <A href="secadv.html" onMouseOut="rolloverOff('side-secadv');" onMouseOver="rolloverOn('side-secadv');"><IMG alt="Advisories" border="0" height="12" hspace="0" name="side-secadv" onLoad="rolloverLoad('side-secadv','graphics/secadv-label-2.jpg','graphics/secadv-label-3.jpg');" src="graphics/secadv-label-3.jpg" vspace="0" width="120"></A><BR>
  8. <A href="http://xerces.apache.org/xerces-c/download.cgi" onMouseOut="rolloverOff('side-ext-18');" onMouseOver="rolloverOn('side-ext-18');"><IMG alt="Download" border="0" height="12" hspace="0" name="side-ext-18" onLoad="rolloverLoad('side-ext-18','graphics/ext-18-label-2.jpg','graphics/ext-18-label-3.jpg');" src="graphics/ext-18-label-3.jpg" vspace="0" width="120"></A><BR>
  9. <IMG border="0" height="6" hspace="0" src="resources/separator.gif" vspace="0" width="120"><BR>
  10. <IMG alt="Xerces-C++ 3.1.2" border="0" height="17" hspace="0" name="side-sect-24" src="graphics/sect-24-label.jpg" vspace="0" width="120"><BR>
  11. <A href="install-3.html" onMouseOut="rolloverOff('side-install-3');" onMouseOver="rolloverOn('side-install-3');"><IMG alt="Installation" border="0" height="12" hspace="0" name="side-install-3" onLoad="rolloverLoad('side-install-3','graphics/install-3-label-2.jpg','graphics/install-3-label-3.jpg');" src="graphics/install-3-label-3.jpg" vspace="0" width="120"></A><BR>
  12. <A href="build-3.html" onMouseOut="rolloverOff('side-build-3');" onMouseOver="rolloverOn('side-build-3');"><IMG alt="Build Instructions" border="0" height="12" hspace="0" name="side-build-3" onLoad="rolloverLoad('side-build-3','graphics/build-3-label-2.jpg','graphics/build-3-label-3.jpg');" src="graphics/build-3-label-3.jpg" vspace="0" width="120"></A><BR>
  13. <IMG border="0" height="6" hspace="0" src="resources/separator-space.gif" vspace="0" width="120"><BR>
  14. <A href="program-3.html" onMouseOut="rolloverOff('side-program-3');" onMouseOver="rolloverOn('side-program-3');"><IMG alt="Programming" border="0" height="12" hspace="0" name="side-program-3" onLoad="rolloverLoad('side-program-3','graphics/program-3-label-2.jpg','graphics/program-3-label-3.jpg');" src="graphics/program-3-label-3.jpg" vspace="0" width="120"></A><BR>
  15. <A href="samples-3.html" onMouseOut="rolloverOff('side-samples-3');" onMouseOver="rolloverOn('side-samples-3');"><IMG alt="Samples" border="0" height="12" hspace="0" name="side-samples-3" onLoad="rolloverLoad('side-samples-3','graphics/samples-3-label-2.jpg','graphics/samples-3-label-3.jpg');" src="graphics/samples-3-label-3.jpg" vspace="0" width="120"></A><BR>
  16. <A href="faqs-3.html" onMouseOut="rolloverOff('side-faqs-3');" onMouseOver="rolloverOn('side-faqs-3');"><IMG alt="FAQs" border="0" height="12" hspace="0" name="side-faqs-3" onLoad="rolloverLoad('side-faqs-3','graphics/faqs-3-label-2.jpg','graphics/faqs-3-label-3.jpg');" src="graphics/faqs-3-label-3.jpg" vspace="0" width="120"></A><BR>
  17. <IMG border="0" height="6" hspace="0" src="resources/separator-space.gif" vspace="0" width="120"><BR>
  18. <A href="api-3.html" onMouseOut="rolloverOff('side-api-3');" onMouseOver="rolloverOn('side-api-3');"><IMG alt="API Reference" border="0" height="12" hspace="0" name="side-api-3" onLoad="rolloverLoad('side-api-3','graphics/api-3-label-2.jpg','graphics/api-3-label-3.jpg');" src="graphics/api-3-label-3.jpg" vspace="0" width="120"></A><BR>
  19. <A href="ApacheDOMC++Binding.html" onMouseOut="rolloverOff('side-ext-84');" onMouseOver="rolloverOn('side-ext-84');"><IMG alt="DOM C++ Binding" border="0" height="12" hspace="0" name="side-ext-84" onLoad="rolloverLoad('side-ext-84','graphics/ext-84-label-2.jpg','graphics/ext-84-label-3.jpg');" src="graphics/ext-84-label-3.jpg" vspace="0" width="120"></A><BR>
  20. <A href="migrate-3.html" onMouseOut="rolloverOff('side-migrate-3');" onMouseOver="rolloverOn('side-migrate-3');"><IMG alt="Migration Guide" border="0" height="12" hspace="0" name="side-migrate-3" onLoad="rolloverLoad('side-migrate-3','graphics/migrate-3-label-2.jpg','graphics/migrate-3-label-3.jpg');" src="graphics/migrate-3-label-3.jpg" vspace="0" width="120"></A><BR>
  21. <IMG border="0" height="6" hspace="0" src="resources/separator.gif" vspace="0" width="120"><BR>
  22. <A href="feedback.html" onMouseOut="rolloverOff('side-feedback');" onMouseOver="rolloverOn('side-feedback');"><IMG alt="Feedback" border="0" height="12" hspace="0" name="side-feedback" onLoad="rolloverLoad('side-feedback','graphics/feedback-label-2.jpg','graphics/feedback-label-3.jpg');" src="graphics/feedback-label-3.jpg" vspace="0" width="120"></A><BR>
  23. <A href="bug-report.html" onMouseOut="rolloverOff('side-bug-report');" onMouseOver="rolloverOn('side-bug-report');"><IMG alt="Bug-Reporting" border="0" height="12" hspace="0" name="side-bug-report" onLoad="rolloverLoad('side-bug-report','graphics/bug-report-label-2.jpg','graphics/bug-report-label-3.jpg');" src="graphics/bug-report-label-3.jpg" vspace="0" width="120"></A><BR>
  24. <A href="mailing-lists.html" onMouseOut="rolloverOff('side-mailing-lists');" onMouseOver="rolloverOn('side-mailing-lists');"><IMG alt="Mailing Lists" border="0" height="12" hspace="0" name="side-mailing-lists" onLoad="rolloverLoad('side-mailing-lists','graphics/mailing-lists-label-2.jpg','graphics/mailing-lists-label-3.jpg');" src="graphics/mailing-lists-label-3.jpg" vspace="0" width="120"></A><BR>
  25. <IMG border="0" height="6" hspace="0" src="resources/separator.gif" vspace="0" width="120"><BR>
  26. <A href="source-repository.html" onMouseOut="rolloverOff('side-source-repository');" onMouseOver="rolloverOn('side-source-repository');"><IMG alt="Source Repository" border="0" height="12" hspace="0" name="side-source-repository" onLoad="rolloverLoad('side-source-repository','graphics/source-repository-label-2.jpg','graphics/source-repository-label-3.jpg');" src="graphics/source-repository-label-3.jpg" vspace="0" width="120"></A><BR>
  27. <A href="applications.html" onMouseOut="rolloverOff('side-applications');" onMouseOver="rolloverOn('side-applications');"><IMG alt="Applications" border="0" height="12" hspace="0" name="side-applications" onLoad="rolloverLoad('side-applications','graphics/applications-label-2.jpg','graphics/applications-label-3.jpg');" src="graphics/applications-label-3.jpg" vspace="0" width="120"></A><BR>
  28. <IMG border="0" height="14" hspace="0" src="resources/close.gif" vspace="0" width="120"><BR></TD><TD align="left" valign="top" width="500"><TABLE border="0" cellpadding="3" cellspacing="0"><TR><TD>
  29. <A name="UsingSAX2API"><!--anchor--></A>
  30. <TABLE border="0" cellpadding="0" cellspacing="0" width="494"><TR><TD bgcolor="ffffff" colspan="2" width="494"><TABLE border="0" cellpadding="0" cellspacing="0" width="494"><TR><TD bgcolor="#039acc" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#039acc" height="1" width="492"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="492"></TD><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#039acc" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#0086b2" width="492"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="+1"><IMG border="0" height="2" hspace="0" src="resources/void.gif" vspace="0" width="2"><B>Using the SAX2 API</B></FONT></TD><TD bgcolor="#017299" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#017299" height="1" width="492"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="492"></TD><TD bgcolor="#017299" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR></TABLE></TD></TR><TR><TD width="10">&nbsp;</TD><TD width="484"><FONT color="#000000" face="arial,helvetica,sanserif">
  31. <P>The SAX2 API for XML parsers was originally developed for
  32. Java. Please be aware that there is no standard SAX2 API for
  33. C++, and that use of the Xerces-C++ SAX2 API does not
  34. guarantee client code compatibility with other C++ XML
  35. parsers.</P>
  36. <P>The SAX2 API presents a callback based API to the parser. An
  37. application that uses SAX2 provides an instance of a handler
  38. class to the parser. When the parser detects XML constructs,
  39. it calls the methods of the handler class, passing them
  40. information about the construct that was detected. The most
  41. commonly used handler classes are ContentHandler which is
  42. called when XML constructs are recognized, and ErrorHandler
  43. which is called when an error occurs. The header files for the
  44. various SAX2 handler classes are in the <CODE><FONT face="courier, monospaced">xercesc/sax2/</FONT></CODE>
  45. directory.</P>
  46. <P>As a convenience, Xerces-C++ provides DefaultHandler,
  47. a single class which is publicly derived
  48. from all the Handler classes. DefaultHandler's default
  49. implementation of the handler callback methods is to do
  50. nothing. A convenient way to get started with Xerces-C++ is
  51. to derive your own handler class from DefaultHandler and override
  52. just those methods in HandlerBase which you are interested in
  53. customizing. This simple example shows how to create a handler
  54. which will print element names, and print fatal error
  55. messages. The source code for the sample applications show
  56. additional examples of how to write handler classes.</P>
  57. <P>This is the header file MySAX2Handler.hpp:</P>
  58. <DIV align="left"><TABLE border="0" cellpadding="0" cellspacing="4" width="464"><TR><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#0086b2" height="1" width="462"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="462"></TD><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#0086b2" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#ffffff" width="462"><FONT size="-1"><PRE>#include &lt;xercesc/sax2/DefaultHandler.hpp&gt;
  59. class MySAX2Handler : public DefaultHandler {
  60. public:
  61. void startElement(
  62. const XMLCh* const uri,
  63. const XMLCh* const localname,
  64. const XMLCh* const qname,
  65. const Attributes&amp; attrs
  66. );
  67. void fatalError(const SAXParseException&amp;);
  68. };</PRE></FONT></TD><TD bgcolor="#0086b2" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#0086b2" height="1" width="462"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="462"></TD><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR></TABLE></DIV>
  69. <P>This is the implementation file MySAX2Handler.cpp:</P>
  70. <DIV align="left"><TABLE border="0" cellpadding="0" cellspacing="4" width="464"><TR><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#0086b2" height="1" width="462"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="462"></TD><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#0086b2" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#ffffff" width="462"><FONT size="-1"><PRE>#include &quot;MySAX2Handler.hpp&quot;
  71. #include &lt;iostream&gt;
  72. using namespace std;
  73. MySAX2Handler::MySAX2Handler()
  74. {
  75. }
  76. void MySAX2Handler::startElement(const XMLCh* const uri,
  77. const XMLCh* const localname,
  78. const XMLCh* const qname,
  79. const Attributes&amp; attrs)
  80. {
  81. char* message = XMLString::transcode(localname);
  82. cout &lt;&lt; &quot;I saw element: &quot;&lt;&lt; message &lt;&lt; endl;
  83. XMLString::release(&amp;message);
  84. }
  85. void MySAX2Handler::fatalError(const SAXParseException&amp; exception)
  86. {
  87. char* message = XMLString::transcode(exception.getMessage());
  88. cout &lt;&lt; &quot;Fatal Error: &quot; &lt;&lt; message
  89. &lt;&lt; &quot; at line: &quot; &lt;&lt; exception.getLineNumber()
  90. &lt;&lt; endl;
  91. XMLString::release(&amp;message);
  92. }</PRE></FONT></TD><TD bgcolor="#0086b2" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#0086b2" height="1" width="462"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="462"></TD><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR></TABLE></DIV>
  93. <P>The XMLCh and Attributes types are supplied by
  94. Xerces-C++ and are documented in the API Reference.
  95. Examples of their usage appear in the source code to
  96. the sample applications.</P>
  97. </FONT></TD></TR></TABLE><BR>
  98. <A name="SAX2XMLReader"><!--anchor--></A>
  99. <TABLE border="0" cellpadding="0" cellspacing="0" width="494"><TR><TD bgcolor="ffffff" colspan="2" width="494"><TABLE border="0" cellpadding="0" cellspacing="0" width="494"><TR><TD bgcolor="#039acc" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#039acc" height="1" width="492"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="492"></TD><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#039acc" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#0086b2" width="492"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="+1"><IMG border="0" height="2" hspace="0" src="resources/void.gif" vspace="0" width="2"><B>SAX2XMLReader</B></FONT></TD><TD bgcolor="#017299" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#017299" height="1" width="492"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="492"></TD><TD bgcolor="#017299" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR></TABLE></TD></TR><TR><TD width="10">&nbsp;</TD><TD width="484"><FONT color="#000000" face="arial,helvetica,sanserif">
  100. <A name="ConstructParser2"><!--anchor--></A>
  101. <TABLE border="0" cellpadding="0" cellspacing="0" width="484"><TR><TD bgcolor="ffffff" colspan="2" width="484"><TABLE border="0" cellpadding="0" cellspacing="0" width="484"><TR><TD bgcolor="#039acc" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#039acc" height="1" width="482"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="482"></TD><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#039acc" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#0086b2" width="482"><FONT color="#ffffff" face="arial,helvetica,sanserif"><IMG border="0" height="2" hspace="0" src="resources/void.gif" vspace="0" width="2"><B>Constructing an XML Reader</B></FONT></TD><TD bgcolor="#017299" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#017299" height="1" width="482"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="482"></TD><TD bgcolor="#017299" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR></TABLE></TD></TR><TR><TD width="10">&nbsp;</TD><TD width="474"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  102. <P>In order to use Xerces-C++ SAX2 to parse XML files, you will
  103. need to create an instance of the SAX2XMLReader class. The example
  104. below shows the code you need in order to create an instance
  105. of SAX2XMLReader. The ContentHandler and ErrorHandler instances
  106. required by the SAX2 API are provided using the DefaultHandler
  107. class supplied with Xerces-C++.</P>
  108. <DIV align="left"><TABLE border="0" cellpadding="0" cellspacing="4" width="464"><TR><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#0086b2" height="1" width="462"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="462"></TD><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#0086b2" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#ffffff" width="462"><FONT size="-1"><PRE>
  109. #include &lt;xercesc/sax2/SAX2XMLReader.hpp&gt;
  110. #include &lt;xercesc/sax2/XMLReaderFactory.hpp&gt;
  111. #include &lt;xercesc/sax2/DefaultHandler.hpp&gt;
  112. #include &lt;xercesc/util/XMLString.hpp&gt;
  113. #include &lt;iostream&gt;
  114. using namespace std;
  115. using namespace xercesc;
  116. int main (int argc, char* args[]) {
  117. try {
  118. XMLPlatformUtils::Initialize();
  119. }
  120. catch (const XMLException&amp; toCatch) {
  121. char* message = XMLString::transcode(toCatch.getMessage());
  122. cout &lt;&lt; &quot;Error during initialization! :\n&quot;;
  123. cout &lt;&lt; &quot;Exception message is: \n&quot;
  124. &lt;&lt; message &lt;&lt; &quot;\n&quot;;
  125. XMLString::release(&amp;message);
  126. return 1;
  127. }
  128. char* xmlFile = &quot;x1.xml&quot;;
  129. SAX2XMLReader* parser = XMLReaderFactory::createXMLReader();
  130. parser-&gt;setFeature(XMLUni::fgSAX2CoreValidation, true);
  131. parser-&gt;setFeature(XMLUni::fgSAX2CoreNameSpaces, true); // optional
  132. DefaultHandler* defaultHandler = new DefaultHandler();
  133. parser-&gt;setContentHandler(defaultHandler);
  134. parser-&gt;setErrorHandler(defaultHandler);
  135. try {
  136. parser-&gt;parse(xmlFile);
  137. }
  138. catch (const XMLException&amp; toCatch) {
  139. char* message = XMLString::transcode(toCatch.getMessage());
  140. cout &lt;&lt; &quot;Exception message is: \n&quot;
  141. &lt;&lt; message &lt;&lt; &quot;\n&quot;;
  142. XMLString::release(&amp;message);
  143. return -1;
  144. }
  145. catch (const SAXParseException&amp; toCatch) {
  146. char* message = XMLString::transcode(toCatch.getMessage());
  147. cout &lt;&lt; &quot;Exception message is: \n&quot;
  148. &lt;&lt; message &lt;&lt; &quot;\n&quot;;
  149. XMLString::release(&amp;message);
  150. return -1;
  151. }
  152. catch (...) {
  153. cout &lt;&lt; &quot;Unexpected Exception \n&quot; ;
  154. return -1;
  155. }
  156. delete parser;
  157. delete defaultHandler;
  158. return 0;
  159. }</PRE></FONT></TD><TD bgcolor="#0086b2" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#0086b2" height="1" width="462"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="462"></TD><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR></TABLE></DIV>
  160. </FONT></TD></TR></TABLE><BR>
  161. <A name="SAX2Features"><!--anchor--></A>
  162. <TABLE border="0" cellpadding="0" cellspacing="0" width="484"><TR><TD bgcolor="ffffff" colspan="2" width="484"><TABLE border="0" cellpadding="0" cellspacing="0" width="484"><TR><TD bgcolor="#039acc" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#039acc" height="1" width="482"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="482"></TD><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#039acc" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#0086b2" width="482"><FONT color="#ffffff" face="arial,helvetica,sanserif"><IMG border="0" height="2" hspace="0" src="resources/void.gif" vspace="0" width="2"><B>Supported Features in SAX2XMLReader</B></FONT></TD><TD bgcolor="#017299" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#017299" height="1" width="482"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="482"></TD><TD bgcolor="#017299" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR></TABLE></TD></TR><TR><TD width="10">&nbsp;</TD><TD width="474"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  163. <P>The behavior of the SAX2XMLReader is dependant on the values of the following features.
  164. All of the features below can be set using the function <CODE><FONT face="courier, monospaced">SAX2XMLReader::setFeature(cons XMLCh* const, const bool)</FONT></CODE>.
  165. And can be queried using the function <CODE><FONT face="courier, monospaced">bool SAX2XMLReader::getFeature(const XMLCh* const)</FONT></CODE>.
  166. </P>
  167. <P>None of these features can be modified in the middle of a parse, or an exception will be thrown.</P>
  168. <TABLE border="0" cellpadding="0" cellspacing="0" width="474"><TR><TD bgcolor="ffffff" colspan="2" width="484"><TABLE border="0" cellpadding="0" cellspacing="0" width="474"><TR><TD bgcolor="#039acc" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#039acc" height="1" width="472"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="472"></TD><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#039acc" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#0086b2" width="472"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><IMG border="0" height="2" hspace="0" src="resources/void.gif" vspace="0" width="2"><B>SAX2 Features</B></FONT></TD><TD bgcolor="#017299" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#017299" height="1" width="472"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="472"></TD><TD bgcolor="#017299" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR></TABLE></TD></TR><TR><TD width="10">&nbsp;</TD><TD width="464"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  169. <A name="namespaces"><!--anchor--></A>
  170. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  171. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://xml.org/sax/features/namespaces</B></B>&nbsp;
  172. </FONT></TD></TR>
  173. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  174. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Perform Namespace processing. &nbsp;
  175. </FONT></TD></TR>
  176. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  177. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Do not perform Namespace processing. &nbsp;
  178. </FONT></TD></TR>
  179. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  180. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> true &nbsp;
  181. </FONT></TD></TR>
  182. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  183. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgSAX2CoreNameSpaces &nbsp;
  184. </FONT></TD></TR>
  185. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>note:</B></B>&nbsp;
  186. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> If the validation feature is set to true, then the
  187. document must contain a grammar that supports the use of namespaces. &nbsp;
  188. </FONT></TD></TR>
  189. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>see:</B></B>&nbsp;
  190. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  191. <A href="#namespace-prefixes">http://xml.org/sax/features/namespace-prefixes </A>
  192. &nbsp;
  193. </FONT></TD></TR>
  194. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>see:</B></B>&nbsp;
  195. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  196. <A href="#validation">http://xml.org/sax/features/validation</A>
  197. &nbsp;
  198. </FONT></TD></TR>
  199. </TABLE>
  200. <P></P>
  201. <A name="namespace-prefixes"><!--anchor--></A>
  202. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  203. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://xml.org/sax/features/namespace-prefixes</B></B>&nbsp;
  204. </FONT></TD></TR>
  205. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  206. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Report the original prefixed names and attributes used for Namespace declarations. &nbsp;
  207. </FONT></TD></TR>
  208. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  209. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Do not report attributes used for Namespace declarations, and optionally do not report original prefixed names. &nbsp;
  210. </FONT></TD></TR>
  211. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  212. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> false &nbsp;
  213. </FONT></TD></TR>
  214. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  215. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgSAX2CoreNameSpacePrefixes &nbsp;
  216. </FONT></TD></TR>
  217. </TABLE>
  218. <P></P>
  219. <A name="validation"><!--anchor--></A>
  220. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  221. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://xml.org/sax/features/validation</B></B>&nbsp;
  222. </FONT></TD></TR>
  223. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  224. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Report all validation errors. &nbsp;
  225. </FONT></TD></TR>
  226. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  227. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Do not report validation errors. &nbsp;
  228. </FONT></TD></TR>
  229. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  230. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> false &nbsp;
  231. </FONT></TD></TR>
  232. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  233. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgSAX2CoreValidation &nbsp;
  234. </FONT></TD></TR>
  235. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>note:</B></B>&nbsp;
  236. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> If this feature is set to true, the document must
  237. specify a grammar. If this feature is set to false and document specifies a grammar,
  238. that grammar might be parsed but no validation of the document contents will be
  239. performed. &nbsp;
  240. </FONT></TD></TR>
  241. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>see:</B></B>&nbsp;
  242. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  243. <A href="#validation-dynamic">http://apache.org/xml/features/validation/dynamic</A>
  244. &nbsp;
  245. </FONT></TD></TR>
  246. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>see:</B></B>&nbsp;
  247. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  248. <A href="#load-external-dtd">http://apache.org/xml/features/nonvalidating/load-external-dtd</A>
  249. &nbsp;
  250. </FONT></TD></TR>
  251. </TABLE>
  252. </FONT></TD></TR></TABLE><BR>
  253. <TABLE border="0" cellpadding="0" cellspacing="0" width="474"><TR><TD bgcolor="ffffff" colspan="2" width="484"><TABLE border="0" cellpadding="0" cellspacing="0" width="474"><TR><TD bgcolor="#039acc" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#039acc" height="1" width="472"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="472"></TD><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#039acc" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#0086b2" width="472"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><IMG border="0" height="2" hspace="0" src="resources/void.gif" vspace="0" width="2"><B>Xerces Features</B></FONT></TD><TD bgcolor="#017299" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#017299" height="1" width="472"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="472"></TD><TD bgcolor="#017299" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR></TABLE></TD></TR><TR><TD width="10">&nbsp;</TD><TD width="464"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  254. <A name="validation-dynamic"><!--anchor--></A>
  255. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  256. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/features/validation/dynamic</B></B>&nbsp;
  257. </FONT></TD></TR>
  258. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  259. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> The parser will validate the document only if a grammar is specified. (http://xml.org/sax/features/validation must be true). &nbsp;
  260. </FONT></TD></TR>
  261. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  262. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Validation is determined by the state of the http://xml.org/sax/features/validation feature. &nbsp;
  263. </FONT></TD></TR>
  264. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  265. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> false &nbsp;
  266. </FONT></TD></TR>
  267. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  268. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesDynamic &nbsp;
  269. </FONT></TD></TR>
  270. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>see:</B></B>&nbsp;
  271. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  272. <A href="#validation">http://xml.org/sax/features/validation</A>
  273. &nbsp;
  274. </FONT></TD></TR>
  275. </TABLE>
  276. <P></P>
  277. <A name="schema"><!--anchor--></A>
  278. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  279. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/features/validation/schema</B></B>&nbsp;
  280. </FONT></TD></TR>
  281. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  282. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Enable the parser's schema support. &nbsp;
  283. </FONT></TD></TR>
  284. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  285. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Disable the parser's schema support. &nbsp;
  286. </FONT></TD></TR>
  287. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  288. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> true &nbsp;
  289. </FONT></TD></TR>
  290. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  291. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesSchema &nbsp;
  292. </FONT></TD></TR>
  293. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>note</B></B>&nbsp;
  294. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> If set to true, namespace processing must also be turned on. &nbsp;
  295. </FONT></TD></TR>
  296. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>see:</B></B>&nbsp;
  297. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  298. <A href="#namespaces">http://xml.org/sax/features/namespaces</A>
  299. &nbsp;
  300. </FONT></TD></TR>
  301. </TABLE>
  302. <P></P>
  303. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  304. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/features/validation/schema-full-checking</B></B>&nbsp;
  305. </FONT></TD></TR>
  306. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  307. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Enable full schema constraint checking, including checking
  308. which may be time-consuming or memory intensive. Currently, particle unique
  309. attribution constraint checking and particle derivation restriction checking
  310. are controlled by this option. &nbsp;
  311. </FONT></TD></TR>
  312. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  313. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Disable full schema constraint checking. &nbsp;
  314. </FONT></TD></TR>
  315. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  316. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> false &nbsp;
  317. </FONT></TD></TR>
  318. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  319. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesSchemaFullChecking &nbsp;
  320. </FONT></TD></TR>
  321. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>note:</B></B>&nbsp;
  322. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> This feature checks the schema grammar itself for
  323. additional errors that are time-consuming or memory intensive. It does <B>not</B> affect the
  324. level of checking performed on document instances that use schema grammars. &nbsp;
  325. </FONT></TD></TR>
  326. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>see:</B></B>&nbsp;
  327. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  328. <A href="#schema">http://apache.org/xml/features/validation/schema</A>
  329. &nbsp;
  330. </FONT></TD></TR>
  331. </TABLE>
  332. <P></P>
  333. <A name="load-schema"><!--anchor--></A>
  334. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  335. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/features/validating/load-schema</B></B>&nbsp;
  336. </FONT></TD></TR>
  337. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  338. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Load the schema. &nbsp;
  339. </FONT></TD></TR>
  340. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  341. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Don't load the schema if it wasn't found in the grammar pool. &nbsp;
  342. </FONT></TD></TR>
  343. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  344. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> true &nbsp;
  345. </FONT></TD></TR>
  346. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  347. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesLoadSchema &nbsp;
  348. </FONT></TD></TR>
  349. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>note:</B></B>&nbsp;
  350. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> This feature is ignored and no schemas are loaded if schema processing is disabled. &nbsp;
  351. </FONT></TD></TR>
  352. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>see:</B></B>&nbsp;
  353. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  354. <A href="#schema">http://apache.org/xml/features/validation/schema</A>
  355. &nbsp;
  356. </FONT></TD></TR>
  357. </TABLE>
  358. <P></P>
  359. <A name="load-external-dtd"><!--anchor--></A>
  360. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  361. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/features/nonvalidating/load-external-dtd</B></B>&nbsp;
  362. </FONT></TD></TR>
  363. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  364. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Load the external DTD. &nbsp;
  365. </FONT></TD></TR>
  366. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  367. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Ignore the external DTD completely. &nbsp;
  368. </FONT></TD></TR>
  369. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  370. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> true &nbsp;
  371. </FONT></TD></TR>
  372. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  373. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesLoadExternalDTD &nbsp;
  374. </FONT></TD></TR>
  375. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>note</B></B>&nbsp;
  376. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> This feature is ignored and DTD is always loaded when validation is on. &nbsp;
  377. </FONT></TD></TR>
  378. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>see:</B></B>&nbsp;
  379. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  380. <A href="#validation">http://xml.org/sax/features/validation</A>
  381. &nbsp;
  382. </FONT></TD></TR>
  383. </TABLE>
  384. <P></P>
  385. <A name="continue-after-fatal"><!--anchor--></A>
  386. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  387. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/features/continue-after-fatal-error</B></B>&nbsp;
  388. </FONT></TD></TR>
  389. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  390. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Attempt to continue parsing after a fatal error. &nbsp;
  391. </FONT></TD></TR>
  392. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  393. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Stops parse on first fatal error. &nbsp;
  394. </FONT></TD></TR>
  395. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  396. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> false &nbsp;
  397. </FONT></TD></TR>
  398. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  399. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesContinueAfterFatalError &nbsp;
  400. </FONT></TD></TR>
  401. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>note:</B></B>&nbsp;
  402. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> The behavior of the parser when this feature is set to
  403. true is <B>undetermined</B>! Therefore use this feature with extreme caution because
  404. the parser may get stuck in an infinite loop or worse. &nbsp;
  405. </FONT></TD></TR>
  406. </TABLE>
  407. <P></P>
  408. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  409. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/features/validation-error-as-fatal</B></B>&nbsp;
  410. </FONT></TD></TR>
  411. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  412. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> The parser will treat validation error as fatal and will
  413. exit depends on the state of
  414. <A href="#continue-after-fatal">http://apache.org/xml/features/continue-after-fatal-error</A>.
  415. &nbsp;
  416. </FONT></TD></TR>
  417. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  418. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> The parser will report the error and continue processing. &nbsp;
  419. </FONT></TD></TR>
  420. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  421. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> false &nbsp;
  422. </FONT></TD></TR>
  423. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  424. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesValidationErrorAsFatal &nbsp;
  425. </FONT></TD></TR>
  426. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>note:</B></B>&nbsp;
  427. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Setting this true does not mean the validation error will
  428. be printed with the word &quot;Fatal Error&quot;. It is still printed as &quot;Error&quot;, but the parser
  429. will exit if
  430. <A href="#continue-after-fatal">http://apache.org/xml/features/continue-after-fatal-error</A>
  431. is set to false. &nbsp;
  432. </FONT></TD></TR>
  433. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>see:</B></B>&nbsp;
  434. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  435. <A href="#continue-after-fatal">http://apache.org/xml/features/continue-after-fatal-error</A>
  436. &nbsp;
  437. </FONT></TD></TR>
  438. </TABLE>
  439. <P></P>
  440. <A name="use-cached"><!--anchor--></A>
  441. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  442. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/features/validation/use-cachedGrammarInParse</B></B>&nbsp;
  443. </FONT></TD></TR>
  444. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  445. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">Use cached grammar if it exists in the pool.&nbsp;
  446. </FONT></TD></TR>
  447. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  448. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">Parse the schema grammar.&nbsp;
  449. </FONT></TD></TR>
  450. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  451. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> false &nbsp;
  452. </FONT></TD></TR>
  453. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  454. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesUseCachedGrammarInParse &nbsp;
  455. </FONT></TD></TR>
  456. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>note:</B></B>&nbsp;
  457. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">If http://apache.org/xml/features/validation/cache-grammarFromParse is enabled,
  458. this feature is set to true automatically and any setting to this feature by the user is a no-op.&nbsp;
  459. </FONT></TD></TR>
  460. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>see:</B></B>&nbsp;
  461. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  462. <A href="#cache-grammar">http://apache.org/xml/features/validation/cache-grammarFromParse</A>
  463. &nbsp;
  464. </FONT></TD></TR>
  465. </TABLE>
  466. <P></P>
  467. <A name="cache-grammar"><!--anchor--></A>
  468. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  469. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/features/validation/cache-grammarFromParse</B></B>&nbsp;
  470. </FONT></TD></TR>
  471. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  472. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">Cache the grammar in the pool for re-use in subsequent parses.&nbsp;
  473. </FONT></TD></TR>
  474. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  475. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">Do not cache the grammar in the pool&nbsp;
  476. </FONT></TD></TR>
  477. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  478. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> false &nbsp;
  479. </FONT></TD></TR>
  480. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  481. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesCacheGrammarFromParse &nbsp;
  482. </FONT></TD></TR>
  483. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>note:</B></B>&nbsp;
  484. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> If set to true, the http://apache.org/xml/features/validation/use-cachedGrammarInParse
  485. is also set to true automatically.&nbsp;
  486. </FONT></TD></TR>
  487. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>see:</B></B>&nbsp;
  488. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  489. <A href="#use-cached">http://apache.org/xml/features/validation/use-cachedGrammarInParse</A>
  490. &nbsp;
  491. </FONT></TD></TR>
  492. </TABLE>
  493. <P></P>
  494. <A name="StandardUriConformant"><!--anchor--></A>
  495. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  496. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/features/standard-uri-conformant</B></B>&nbsp;
  497. </FONT></TD></TR>
  498. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  499. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Force standard uri conformance. &nbsp;
  500. </FONT></TD></TR>
  501. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  502. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Do not force standard uri conformance. &nbsp;
  503. </FONT></TD></TR>
  504. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  505. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> false &nbsp;
  506. </FONT></TD></TR>
  507. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  508. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesStandardUriConformant &nbsp;
  509. </FONT></TD></TR>
  510. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>note:</B></B>&nbsp;
  511. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> If set to true, malformed uri will be rejected
  512. and fatal error will be issued. &nbsp;
  513. </FONT></TD></TR>
  514. </TABLE>
  515. <P></P>
  516. <A name="CalculateSrcOffset"><!--anchor--></A>
  517. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  518. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/features/calculate-src-ofs</B></B>&nbsp;
  519. </FONT></TD></TR>
  520. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  521. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Enable src offset calculation. &nbsp;
  522. </FONT></TD></TR>
  523. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  524. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Disable src offset calculation. &nbsp;
  525. </FONT></TD></TR>
  526. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  527. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> false &nbsp;
  528. </FONT></TD></TR>
  529. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  530. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesCalculateSrcOfs &nbsp;
  531. </FONT></TD></TR>
  532. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>note:</B></B>&nbsp;
  533. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> If set to true, the user can inquire about
  534. the current src offset within the input source. Setting it to false (default)
  535. improves the performance.&nbsp;
  536. </FONT></TD></TR>
  537. </TABLE>
  538. <P></P>
  539. <A name="IdentityConstraintChecking"><!--anchor--></A>
  540. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  541. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/features/validation/identity-constraint-checking</B></B>&nbsp;
  542. </FONT></TD></TR>
  543. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  544. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Enable identity constraint checking. &nbsp;
  545. </FONT></TD></TR>
  546. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  547. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Disable identity constraint checking. &nbsp;
  548. </FONT></TD></TR>
  549. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  550. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> true &nbsp;
  551. </FONT></TD></TR>
  552. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  553. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesIdentityConstraintChecking &nbsp;
  554. </FONT></TD></TR>
  555. </TABLE>
  556. <P></P>
  557. <A name="GenerateSyntheticAnnotations"><!--anchor--></A>
  558. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  559. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/features/generate-synthetic-annotations</B></B>&nbsp;
  560. </FONT></TD></TR>
  561. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  562. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Enable generation of synthetic annotations. A synthetic annotation will be
  563. generated when a schema component has non-schema attributes but no child annotation. &nbsp;
  564. </FONT></TD></TR>
  565. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  566. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Disable generation of synthetic annotations. &nbsp;
  567. </FONT></TD></TR>
  568. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  569. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> false &nbsp;
  570. </FONT></TD></TR>
  571. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  572. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesGenerateSyntheticAnnotations &nbsp;
  573. </FONT></TD></TR>
  574. </TABLE>
  575. <P></P>
  576. <A name="XercesValidateAnnotations"><!--anchor--></A>
  577. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  578. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/features/validate-annotations</B></B>&nbsp;
  579. </FONT></TD></TR>
  580. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  581. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Enable validation of annotations. &nbsp;
  582. </FONT></TD></TR>
  583. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  584. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Disable validation of annotations. &nbsp;
  585. </FONT></TD></TR>
  586. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  587. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> false &nbsp;
  588. </FONT></TD></TR>
  589. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  590. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesValidateAnnotations &nbsp;
  591. </FONT></TD></TR>
  592. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>note:</B></B>&nbsp;
  593. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Each annotation is validated independently. &nbsp;
  594. </FONT></TD></TR>
  595. </TABLE>
  596. <P></P>
  597. <A name="IgnoreAnnotations"><!--anchor--></A>
  598. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  599. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/features/schema/ignore-annotations</B></B>&nbsp;
  600. </FONT></TD></TR>
  601. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  602. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Do not generate XSAnnotations when traversing a schema.&nbsp;
  603. </FONT></TD></TR>
  604. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  605. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Generate XSAnnotations when traversing a schema.&nbsp;
  606. </FONT></TD></TR>
  607. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  608. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> false &nbsp;
  609. </FONT></TD></TR>
  610. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  611. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesIgnoreAnnotations &nbsp;
  612. </FONT></TD></TR>
  613. </TABLE>
  614. <P></P>
  615. <A name="DisableDefaultEntityResolution"><!--anchor--></A>
  616. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  617. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/features/disable-default-entity-resolution</B></B>&nbsp;
  618. </FONT></TD></TR>
  619. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  620. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> The parser will not attempt to resolve the entity when the resolveEntity method returns NULL.&nbsp;
  621. </FONT></TD></TR>
  622. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  623. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> The parser will attempt to resolve the entity when the resolveEntity method returns NULL.&nbsp;
  624. </FONT></TD></TR>
  625. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  626. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> false &nbsp;
  627. </FONT></TD></TR>
  628. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  629. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesDisableDefaultEntityResolution &nbsp;
  630. </FONT></TD></TR>
  631. </TABLE>
  632. <P></P>
  633. <A name="SkipDTDValidation"><!--anchor--></A>
  634. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  635. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/features/validation/schema/skip-dtd-validation</B></B>&nbsp;
  636. </FONT></TD></TR>
  637. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  638. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> When schema validation is on the parser will ignore the DTD, except for entities.&nbsp;
  639. </FONT></TD></TR>
  640. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  641. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> The parser will not ignore DTDs when validating.&nbsp;
  642. </FONT></TD></TR>
  643. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  644. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> false &nbsp;
  645. </FONT></TD></TR>
  646. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  647. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesSkipDTDValidation &nbsp;
  648. </FONT></TD></TR>
  649. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>see:</B></B>&nbsp;
  650. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  651. <A href="#schema">Schema Validation</A>&nbsp;
  652. </FONT></TD></TR>
  653. </TABLE>
  654. <P></P>
  655. <A name="IgnoreCachedDTD"><!--anchor--></A>
  656. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  657. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/features/validation/ignoreCachedDTD</B></B>&nbsp;
  658. </FONT></TD></TR>
  659. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  660. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Ignore a cached DTD when an XML document contains both an
  661. internal and external DTD, and the use cached grammar from parse option
  662. is enabled. Currently, we do not allow using cached DTD grammar when an
  663. internal subset is present in the document. This option will only affect
  664. the behavior of the parser when an internal and external DTD both exist
  665. in a document (i.e. no effect if document has no internal subset).&nbsp;
  666. </FONT></TD></TR>
  667. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  668. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Don't ignore cached DTD. &nbsp;
  669. </FONT></TD></TR>
  670. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  671. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> false &nbsp;
  672. </FONT></TD></TR>
  673. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  674. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesIgnoreCachedDTD &nbsp;
  675. </FONT></TD></TR>
  676. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>see:</B></B>&nbsp;
  677. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  678. <A href="#use-cached">http://apache.org/xml/features/validation/use-cachedGrammarInParse</A>
  679. &nbsp;
  680. </FONT></TD></TR>
  681. </TABLE>
  682. <P></P>
  683. <A name="HandleMultipleImports"><!--anchor--></A>
  684. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  685. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/features/validation/schema/handle-multiple-imports</B></B>&nbsp;
  686. </FONT></TD></TR>
  687. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>true:</B></B>&nbsp;
  688. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> During schema validation allow multiple schemas with the same namespace
  689. to be imported.&nbsp;
  690. </FONT></TD></TR>
  691. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>false:</B></B>&nbsp;
  692. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> Don't import multiple schemas with the same namespace. &nbsp;
  693. </FONT></TD></TR>
  694. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>default:</B></B>&nbsp;
  695. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> false &nbsp;
  696. </FONT></TD></TR>
  697. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  698. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesHandleMultipleImports &nbsp;
  699. </FONT></TD></TR>
  700. </TABLE>
  701. <P></P>
  702. </FONT></TD></TR></TABLE><BR>
  703. </FONT></TD></TR></TABLE><BR>
  704. <A name="SAX2Properties"><!--anchor--></A>
  705. <TABLE border="0" cellpadding="0" cellspacing="0" width="484"><TR><TD bgcolor="ffffff" colspan="2" width="484"><TABLE border="0" cellpadding="0" cellspacing="0" width="484"><TR><TD bgcolor="#039acc" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#039acc" height="1" width="482"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="482"></TD><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#039acc" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#0086b2" width="482"><FONT color="#ffffff" face="arial,helvetica,sanserif"><IMG border="0" height="2" hspace="0" src="resources/void.gif" vspace="0" width="2"><B>Supported Properties in SAX2XMLReader</B></FONT></TD><TD bgcolor="#017299" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#017299" height="1" width="482"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="482"></TD><TD bgcolor="#017299" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR></TABLE></TD></TR><TR><TD width="10">&nbsp;</TD><TD width="474"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  706. <P>The behavior of the SAX2XMLReader is dependant on the values of the following properties.
  707. All of the properties below can be set using the function <CODE><FONT face="courier, monospaced">SAX2XMLReader::setProperty(const XMLCh* const, void*)</FONT></CODE>.
  708. It takes a void pointer as the property value. Application is required to initialize this void
  709. pointer to a correct type. Please check the column &quot;Value Type&quot; below
  710. to learn exactly what type of property value each property expects for processing.
  711. Passing a void pointer that was initialized with a wrong type will lead to unexpected result.
  712. If the same property is set more than once, the last one takes effect.</P>
  713. <P>Property values can be queried using the function <CODE><FONT face="courier, monospaced">void* SAX2XMLReader::getProperty(const XMLCh* const)</FONT></CODE>.
  714. The parser owns the returned pointer, and the memory allocated for the returned pointer will
  715. be destroyed when the parser is deleted. To ensure accessibility of the returned information after
  716. the parser is deleted, callers need to copy and store the returned information somewhere else.
  717. Since the returned pointer is a generic void pointer, check the column &quot;Value Type&quot; below to learn
  718. exactly what type of object each property returns for replication.</P>
  719. <P>None of these properties can be modified in the middle of a parse, or an exception will be thrown.</P>
  720. <TABLE border="0" cellpadding="0" cellspacing="0" width="474"><TR><TD bgcolor="ffffff" colspan="2" width="484"><TABLE border="0" cellpadding="0" cellspacing="0" width="474"><TR><TD bgcolor="#039acc" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#039acc" height="1" width="472"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="472"></TD><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#039acc" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#0086b2" width="472"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><IMG border="0" height="2" hspace="0" src="resources/void.gif" vspace="0" width="2"><B>Xerces Properties</B></FONT></TD><TD bgcolor="#017299" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR><TR><TD bgcolor="#0086b2" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD><TD bgcolor="#017299" height="1" width="472"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="472"></TD><TD bgcolor="#017299" height="1" width="1"><IMG border="0" height="1" hspace="0" src="resources/void.gif" vspace="0" width="1"></TD></TR></TABLE></TD></TR><TR><TD width="10">&nbsp;</TD><TD width="464"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  721. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  722. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/properties/schema/external-schemaLocation</B></B>&nbsp;
  723. </FONT></TD></TR>
  724. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>Description</B></B>&nbsp;
  725. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> The XML Schema Recommendation explicitly states that
  726. the inclusion of schemaLocation/ noNamespaceSchemaLocation attributes in the
  727. instance document is only a hint; it does not mandate that these attributes
  728. must be used to locate schemas. Similar situation happens to &lt;import&gt;
  729. element in schema documents. This property allows the user to specify a list
  730. of schemas to use. If the targetNamespace of a schema specified using this
  731. method matches the targetNamespace of a schema occurring in the instance
  732. document in schemaLocation attribute, or
  733. if the targetNamespace matches the namespace attribute of &lt;import&gt;
  734. element, the schema specified by the user using this property will
  735. be used (i.e., the schemaLocation attribute in the instance document
  736. or on the &lt;import&gt; element will be effectively ignored). &nbsp;
  737. </FONT></TD></TR>
  738. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>Value</B></B>&nbsp;
  739. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> The syntax is the same as for schemaLocation attributes
  740. in instance documents: e.g, &quot;http://www.example.com file_name.xsd&quot;.
  741. The user can specify more than one XML Schema in the list. &nbsp;
  742. </FONT></TD></TR>
  743. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>Value Type</B></B>&nbsp;
  744. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> XMLCh* &nbsp;
  745. </FONT></TD></TR>
  746. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  747. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesSchemaExternalSchemaLocation &nbsp;
  748. </FONT></TD></TR>
  749. </TABLE>
  750. <P></P>
  751. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  752. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/properties/schema/external-noNamespaceSchemaLocation</B></B>&nbsp;
  753. </FONT></TD></TR>
  754. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>Description</B></B>&nbsp;
  755. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> The XML Schema Recommendation explicitly states that
  756. the inclusion of schemaLocation/ noNamespaceSchemaLocation attributes in the
  757. instance document is only a hint; it does not mandate that these attributes
  758. must be used to locate schemas. This property allows the user to specify the
  759. no target namespace XML Schema Location externally. If specified, the instance
  760. document's noNamespaceSchemaLocation attribute will be effectively ignored. &nbsp;
  761. </FONT></TD></TR>
  762. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>Value</B></B>&nbsp;
  763. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> The syntax is the same as for the noNamespaceSchemaLocation
  764. attribute that may occur in an instance document: e.g.&quot;file_name.xsd&quot;. &nbsp;
  765. </FONT></TD></TR>
  766. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>Value Type</B></B>&nbsp;
  767. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> XMLCh* &nbsp;
  768. </FONT></TD></TR>
  769. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  770. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesSchemaExternalNoNameSpaceSchemaLocation &nbsp;
  771. </FONT></TD></TR>
  772. </TABLE>
  773. <P></P>
  774. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  775. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/properties/scannerName</B></B>&nbsp;
  776. </FONT></TD></TR>
  777. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>Description</B></B>&nbsp;
  778. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> This property allows the user to specify the name of
  779. the XMLScanner to use for scanning XML documents. If not specified, the default
  780. scanner &quot;IGXMLScanner&quot; is used.&nbsp;
  781. </FONT></TD></TR>
  782. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>Value</B></B>&nbsp;
  783. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> The recognized scanner names are: <BR>
  784. 1.&quot;WFXMLScanner&quot; - scanner that performs well-formedness checking only.<BR>
  785. 2. &quot;DGXMLScanner&quot; - scanner that handles XML documents with DTD grammar information.<BR>
  786. 3. &quot;SGXMLScanner&quot; - scanner that handles XML documents with XML schema grammar information.<BR>
  787. 4. &quot;IGXMLScanner&quot; - scanner that handles XML documents with DTD or/and XML schema grammar information.<BR>
  788. Users can use the predefined constants defined in XMLUni directly (fgWFXMLScanner, fgDGXMLScanner,
  789. fgSGXMLScanner, or fgIGXMLScanner) or a string that matches the value of
  790. one of those constants.&nbsp;
  791. </FONT></TD></TR>
  792. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>Value Type</B></B>&nbsp;
  793. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> XMLCh* &nbsp;
  794. </FONT></TD></TR>
  795. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  796. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesScannerName &nbsp;
  797. </FONT></TD></TR>
  798. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>note: </B></B>&nbsp;
  799. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> See <A href="program-others-3.html#UseSpecificScanner">Use Specific Scanner</A>
  800. for more programming details. &nbsp;
  801. </FONT></TD></TR>
  802. </TABLE>
  803. <P></P>
  804. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  805. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/properties/security-manager</B></B>&nbsp;
  806. </FONT></TD></TR>
  807. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>Description</B></B>&nbsp;
  808. </FONT></TD>
  809. <TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  810. Certain valid XML and XML Schema constructs can force a
  811. processor to consume more system resources than an
  812. application may wish. In fact, certain features could
  813. be exploited by malicious document writers to produce a
  814. denial-of-service attack. This property allows
  815. applications to impose limits on the amount of
  816. resources the processor will consume while processing
  817. these constructs.
  818. &nbsp;
  819. </FONT></TD></TR>
  820. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>Value</B></B>&nbsp;
  821. </FONT></TD>
  822. <TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  823. An instance of the SecurityManager class (see
  824. <CODE><FONT face="courier, monospaced">xercesc/util/SecurityManager</FONT></CODE>). This
  825. class's documentation describes the particular limits
  826. that may be set. Note that, when instantiated, default
  827. values for limits that should be appropriate in most
  828. settings are provided. The default implementation is
  829. not thread-safe; if thread-safety is required, the
  830. application should extend this class, overriding
  831. methods appropriately. The parser will not adopt the
  832. SecurityManager instance; the application is
  833. responsible for deleting it when it is finished with
  834. it. If no SecurityManager instance has been provided to
  835. the parser (the default) then processing strictly
  836. conforming to the relevant specifications will be
  837. performed.
  838. &nbsp;
  839. </FONT></TD></TR>
  840. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>Value Type</B></B>&nbsp;
  841. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> SecurityManager* &nbsp;
  842. </FONT></TD></TR>
  843. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  844. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesSecurityManager &nbsp;
  845. </FONT></TD></TR>
  846. </TABLE>
  847. <P></P>
  848. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  849. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>http://apache.org/xml/properties/low-water-mark</B></B>&nbsp;
  850. </FONT></TD></TR>
  851. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>Description</B></B>&nbsp;
  852. </FONT></TD>
  853. <TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  854. If the number of available bytes in the raw buffer is less than
  855. the low water mark the parser will attempt to read more data before
  856. continuing parsing. By default the value for this parameter is 100
  857. bytes. You may want to set this parameter to 0 if you would like
  858. the parser to parse the available data immediately without
  859. potentially blocking while waiting for more date.
  860. &nbsp;
  861. </FONT></TD></TR>
  862. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>Value</B></B>&nbsp;
  863. </FONT></TD>
  864. <TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  865. New low water mark.
  866. &nbsp;
  867. </FONT></TD></TR>
  868. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>Value Type</B></B>&nbsp;
  869. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> XMLSize_t* &nbsp;
  870. </FONT></TD></TR>
  871. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>XMLUni Predefined Constant:</B></B>&nbsp;
  872. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> fgXercesLowWaterMark &nbsp;
  873. </FONT></TD></TR>
  874. </TABLE>
  875. <P></P>
  876. <TABLE border="0" cellpadding="2" cellspacing="2" width="100%">
  877. <TR><TD align="center" bgcolor="#039acc" colspan="2" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>setInputBufferSize(const size_t bufferSize)</B></B>&nbsp;
  878. </FONT></TD></TR>
  879. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>Description</B></B>&nbsp;
  880. </FONT></TD>
  881. <TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  882. Set maximum input buffer size.
  883. This method allows users to limit the size of buffers used in parsing
  884. XML character data. The effect of setting this size is to limit the
  885. size of a ContentHandler::characters() call.
  886. The parser's default input buffer size is 1 megabyte.
  887. &nbsp;
  888. </FONT></TD></TR>
  889. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>Value</B></B>&nbsp;
  890. </FONT></TD>
  891. <TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1">
  892. The maximum input buffer size
  893. &nbsp;
  894. </FONT></TD></TR>
  895. <TR><TD align="center" bgcolor="#039acc" colspan="1" rowspan="1" valign="center"><FONT color="#ffffff" face="arial,helvetica,sanserif" size="-1"><B><B>Value Type</B></B>&nbsp;
  896. </FONT></TD><TD align="" bgcolor="#a0ddf0" colspan="1" rowspan="1" valign="top"><FONT color="#000000" face="arial,helvetica,sanserif" size="-1"> XMLCh* &nbsp;
  897. </FONT></TD></TR>
  898. </TABLE>
  899. <P></P>
  900. </FONT></TD></TR></TABLE><BR>
  901. </FONT></TD></TR></TABLE><BR>
  902. </FONT></TD></TR></TABLE><BR>
  903. </TD></TR></TABLE></TD></TR></TABLE><BR><TABLE border="0" cellpadding="0" cellspacing="0" width="620"><TR><TD bgcolor="#0086b2"><IMG height="1" src="resources/dot.gif" width="1"></TD></TR><TR><TD align="center"><FONT color="#0086b2" size="-1"><I>
  904. Copyright &copy; 1999-2015 The Apache Software Foundation.
  905. All Rights Reserved.
  906. </I></FONT></TD></TR></TABLE></BODY></HTML>