9#include <xercesc/util/PlatformUtils.hpp>
10#include <xercesc/sax2/SAX2XMLReader.hpp>
12#include "IsisXMLIgnore.h"
13#include "IsisXMLChTrans.h"
17namespace XERCES = XERCES_CPP_NAMESPACE;
21IsisXMLIgnore::IsisXMLIgnore(
char *PencodingName,
22 bool &PexpandNamespaces,
23 XERCES::SAX2XMLReader* &Pparser,
24 const std::string Pignore) {
26 encodingName = PencodingName;
27 expandNamespaces = PexpandNamespaces;
31 prevDocHandler = parser->getContentHandler();
32 prevErrorHandler = parser->getErrorHandler();
34 parser->setContentHandler(
this);
35 parser->setErrorHandler(
this);
40IsisXMLIgnore::~IsisXMLIgnore() {}
43void IsisXMLIgnore::characters(
const XMLCh *
const chars,
44 const XMLSize_t length) {
47void IsisXMLIgnore::endElement(
const XMLCh *
const uri,
48 const XMLCh *
const localname,
49 const XMLCh *
const qname) {
51 if((
string)XERCES::XMLString::transcode(localname) == ignore) {
52 parser->setContentHandler(prevDocHandler);
53 parser->setErrorHandler(prevErrorHandler);
Namespace for the standard library.