diff --git a/doc/faq-parse.xml b/doc/faq-parse.xml index 89a2f8af4f11e8a05b0c5772c3acfe2241279229..1f89530d560fdac371386c3d7cd2203680da39e1 100644 --- a/doc/faq-parse.xml +++ b/doc/faq-parse.xml @@ -700,7 +700,7 @@ catch (const XMLException& toCatch) { <p>To ignore the DTD, with &XercesCName; &XercesCVersion; or up, you can call <code>setLoadExternalDTD(false)</code> (or - <code>setFeature(XMLUni::fgSAX2XercesLoadExternalDTD, false)</code> + <code>setFeature(XMLUni::fgXercesLoadExternalDTD, false)</code> to disable the loading of external DTD. The parser will then ignore any external DTD completely if the validationScheme is set to Val_Never. </p> diff --git a/doc/program-others.xml b/doc/program-others.xml index 43c456c3e948bb877c8bbca93c200430e0d566a9..c064a59a0f9a9692a30b8866668b9e2710d22836 100644 --- a/doc/program-others.xml +++ b/doc/program-others.xml @@ -134,7 +134,7 @@ while (gotMore && !handler.getDone()) // specified in anotherXmlFile is IGNORED. // // Note: The anotherXmlFile cannot have any DTD internal subset. - parser->setFeature(XMLUni::fgSAX2XercesReuseGrammar, true) + parser->setFeature(XMLUni::fgXercesReuseGrammar, true) parser->parse(anotherXmlFile); </source> diff --git a/doc/schema.xml b/doc/schema.xml index 03956f5cddbecafa685d39ecfd7df240612b6bb3..c78d313755676b08a0a3791b213344c03b6cf410 100644 --- a/doc/schema.xml +++ b/doc/schema.xml @@ -67,7 +67,7 @@ parser.parse(xmlFile); </p> <source>SAX2XMLReader* parser = XMLReaderFactory::createXMLReader(); parser->setFeature(XMLUni::fgSAX2CoreNameSpaces, true); -parser->setFeature(XMLUni::fgSAX2XercesSchema, true); +parser->setFeature(XMLUni::fgXercesSchema, true); parser->parse(xmlFile); </source> <p>Review the sample file, 'samples/data/personal-schema.xml' and @@ -104,7 +104,7 @@ XMLCh* propertyValue = XMLString::transcode("personal.xsd"); ArrayJanitor<XMLCh> janValue(propertyValue); parser->setProperty( - XMLUni::fgSAX2XercesSchemaExternalNoNameSpaceSchemaLocation, + XMLUni::fgXercesSchemaExternalNoNameSpaceSchemaLocation, propertyValue); parser.parse("test.xml"); </source> @@ -127,7 +127,7 @@ XMLCh* propertyValue = XMLString::transcode("http://my.com personal.xsd http://m ArrayJanitor<XMLCh> janValue(propertyValue); parser->setProperty( - XMLCh XMLUni::fgSAX2XercesSchemaExternalSchemaLocation, + XMLCh XMLUni::fgXercesSchemaExternalSchemaLocation, propertyValue); parser.parse("test.xml"); </source> diff --git a/samples/SAX2Count/SAX2Count.cpp b/samples/SAX2Count/SAX2Count.cpp index d1a2f130e9b5788205f6322c860937efa102719e..4c192c8e1bc9f3411a4e6c423dba173a840c646c 100644 --- a/samples/SAX2Count/SAX2Count.cpp +++ b/samples/SAX2Count/SAX2Count.cpp @@ -56,6 +56,9 @@ /* * $Log$ +* Revision 1.17 2002/06/17 15:33:05 tng +* Name Xerces features as XMLUni::fgXercesXXXX instead of XMLUni::fgSAX2XercesXXXX so that they can be shared with DOM parser. +* * Revision 1.16 2002/02/13 16:11:06 knoaman * Update samples to use SAX2 features/properties constants from XMLUni. * @@ -260,14 +263,14 @@ int main(int argC, char* argV[]) // SAX2XMLReader* parser = XMLReaderFactory::createXMLReader(); parser->setFeature(XMLUni::fgSAX2CoreNameSpaces, doNamespaces); - parser->setFeature(XMLUni::fgSAX2XercesSchema, doSchema); - parser->setFeature(XMLUni::fgSAX2XercesSchemaFullChecking, schemaFullChecking); + parser->setFeature(XMLUni::fgXercesSchema, doSchema); + parser->setFeature(XMLUni::fgXercesSchemaFullChecking, schemaFullChecking); parser->setFeature(XMLUni::fgSAX2CoreNameSpacePrefixes, namespacePrefixes); if (valScheme == SAX2XMLReader::Val_Auto) { parser->setFeature(XMLUni::fgSAX2CoreValidation, true); - parser->setFeature(XMLUni::fgSAX2XercesDynamic, true); + parser->setFeature(XMLUni::fgXercesDynamic, true); } if (valScheme == SAX2XMLReader::Val_Never) { @@ -276,7 +279,7 @@ int main(int argC, char* argV[]) if (valScheme == SAX2XMLReader::Val_Always) { parser->setFeature(XMLUni::fgSAX2CoreValidation, true); - parser->setFeature(XMLUni::fgSAX2XercesDynamic, false); + parser->setFeature(XMLUni::fgXercesDynamic, false); } // diff --git a/samples/SAX2Print/SAX2Print.cpp b/samples/SAX2Print/SAX2Print.cpp index c93b447f8d93082ac4e079500e7cbab416d10c3e..1a31ec03f866065cfe523230fa5e1939b6e059da 100644 --- a/samples/SAX2Print/SAX2Print.cpp +++ b/samples/SAX2Print/SAX2Print.cpp @@ -56,6 +56,9 @@ /* * $Log$ + * Revision 1.12 2002/06/17 15:33:00 tng + * Name Xerces features as XMLUni::fgXercesXXXX instead of XMLUni::fgSAX2XercesXXXX so that they can be shared with DOM parser. + * * Revision 1.11 2002/05/28 20:20:26 tng * Add option '-n' to SAX2Print. * @@ -303,7 +306,7 @@ int main(int argC, char* argV[]) if (valScheme == SAX2XMLReader::Val_Auto) { parser->setFeature(XMLUni::fgSAX2CoreValidation, true); - parser->setFeature(XMLUni::fgSAX2XercesDynamic, true); + parser->setFeature(XMLUni::fgXercesDynamic, true); } if (valScheme == SAX2XMLReader::Val_Never) @@ -314,12 +317,12 @@ int main(int argC, char* argV[]) if (valScheme == SAX2XMLReader::Val_Always) { parser->setFeature(XMLUni::fgSAX2CoreValidation, true); - parser->setFeature(XMLUni::fgSAX2XercesDynamic, false); + parser->setFeature(XMLUni::fgXercesDynamic, false); } parser->setFeature(XMLUni::fgSAX2CoreNameSpaces, doNamespaces); - parser->setFeature(XMLUni::fgSAX2XercesSchema, doSchema); - parser->setFeature(XMLUni::fgSAX2XercesSchemaFullChecking, schemaFullChecking); + parser->setFeature(XMLUni::fgXercesSchema, doSchema); + parser->setFeature(XMLUni::fgXercesSchemaFullChecking, schemaFullChecking); parser->setFeature(XMLUni::fgSAX2CoreNameSpacePrefixes, namespacePrefixes); //