void TestParser::elementDecl(const DTDElementDecl& decl , const bool isIgnored) { if (fOutputType == OutputType_Debug) { XERCES_STD_QUALIFIER cout << "Got ELEMENT DECL:\n " << "Name: " << StrX(decl.getFullName()); if (isIgnored) XERCES_STD_QUALIFIER cout << " (Ignored)"; XERCES_STD_QUALIFIER cout << ", Content: " << StrX(decl.getFormattedContentModel()) << "\n SrcOfs: " << fScanner->getSrcOffset() << "\n" << XERCES_STD_QUALIFIER endl; } else if (fOutputType != OutputType_None) { if (fInExtSubset) return; if (fIntDTDOutput) { XERCES_STD_QUALIFIER cout << "<!ELEMENT " << StrX(decl.getFullName()) << " " << StrX(decl.getFormattedContentModel()) << ">"; } } }
void TestParser::doctypeDecl(const DTDElementDecl& elemDecl , const XMLCh* const publicId , const XMLCh* const systemId , const bool hasIntSubset) { if (fOutputType == OutputType_Debug) { XERCES_STD_QUALIFIER cout << "Got DOCTYPE:\n " << "Root: " << StrX(elemDecl.getFullName()); if (XMLString::stringLen(publicId)) XERCES_STD_QUALIFIER cout << ", PUBLIC: " << StrX(publicId); if (XMLString::stringLen(systemId)) XERCES_STD_QUALIFIER cout << ", SYSTEM: " << StrX(systemId); XERCES_STD_QUALIFIER cout << "\n SrcOfs: " << fScanner->getSrcOffset() << "\n" << XERCES_STD_QUALIFIER endl; } else if (fOutputType != OutputType_None) { if (fIntDTDOutput) { XERCES_STD_QUALIFIER cout << "<!DOCTYPE " << StrX(elemDecl.getFullName()); showIds(publicId, systemId); if (!hasIntSubset) XERCES_STD_QUALIFIER cout << ">"; } } }
void TestParser::startAttList(const DTDElementDecl& elemDecl) { if (fOutputType == OutputType_Debug) { XERCES_STD_QUALIFIER cout << "Got STARTATTLIST:\n " << "Name: " << StrX(elemDecl.getFullName()) << "\n" << XERCES_STD_QUALIFIER endl; } else if (fOutputType != OutputType_None) { if (fInExtSubset) return; if (fIntDTDOutput) XERCES_STD_QUALIFIER cout << "<!ATTLIST " << StrX(elemDecl.getFullName()); } }
void NsSAX2Reader::startAttList(const DTDElementDecl &elemDecl) { if (fReadingIntSubset) { fSubset.append(chOpenAngle); fSubset.append(chBang); fSubset.append(XMLUni::fgAttListString); fSubset.append(chSpace); fSubset.append(elemDecl.getFullName()); } }
void TestParser::endAttList(const DTDElementDecl& elemDecl) { if (fOutputType == OutputType_Debug) { XERCES_STD_QUALIFIER cout << "Got ENDATTLIST:\n " << "Name: " << StrX(elemDecl.getFullName()) << "\n" << " SrcOfs: " << fScanner->getSrcOffset() << "\n" << XERCES_STD_QUALIFIER endl; } else if (fOutputType != OutputType_None) { if (fInExtSubset) return; if (fIntDTDOutput) XERCES_STD_QUALIFIER cout << ">"; } }
void NsSAX2Reader::elementDecl(const DTDElementDecl& elemDecl, const_bool isIgnored) { if (fReadingIntSubset) { fSubset.append(chOpenAngle); fSubset.append(chBang); fSubset.append(XMLUni::fgElemString); fSubset.append(chSpace); fSubset.append(elemDecl.getFullName()); //get the ContentSpec information const XMLCh* contentModel = elemDecl.getFormattedContentModel(); if (contentModel != 0) { fSubset.append(chSpace); fSubset.append(contentModel); } fSubset.append(chCloseAngle); } }
void NsSAX2Reader::doctypeDecl(const DTDElementDecl& elemDecl, const XMLCh* const publicId, const XMLCh* const systemId, const_bool hasIntSubset, const_bool hasExtSubset) { fSubset.append(XMLUni::fgDocTypeString); fSubset.append(chSpace); fSubset.append(elemDecl.getFullName()); fSubset.append(chSpace); if (publicId && *publicId) { fSubset.append(XMLUni::fgPubIDString); fSubset.append(chSpace); fSubset.append(chDoubleQuote); fSubset.append(publicId); fSubset.append(chDoubleQuote); fSubset.append(chSpace); } if (systemId && *systemId) { if (!(publicId && *publicId)) { fSubset.append(XMLUni::fgSysIDString); fSubset.append(chSpace); } fSubset.append(chDoubleQuote); fSubset.append(systemId); fSubset.append(chDoubleQuote); } if (hasIntSubset) { fSubset.append(gStartIntSubset); fHasIntSubset = true; } else if (hasExtSubset) { fHasExtSubset = true; fSubset.append(gEndExtSubset); } }