You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xerces.apache.org by tn...@apache.org on 2001/11/13 14:25:28 UTC
cvs commit: xml-xerces/c/src/validators/DTD DTDValidator.cpp DTDValidator.hpp
tng 01/11/13 05:25:28
Modified: c/src/validators/DTD DTDValidator.cpp DTDValidator.hpp
Log:
Deprecate function XMLValidator::checkRootElement.
Revision Changes Path
1.22 +4 -16 xml-xerces/c/src/validators/DTD/DTDValidator.cpp
Index: DTDValidator.cpp
===================================================================
RCS file: /home/cvs/xml-xerces/c/src/validators/DTD/DTDValidator.cpp,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -r1.21 -r1.22
--- DTDValidator.cpp 2001/09/05 20:49:10 1.21
+++ DTDValidator.cpp 2001/11/13 13:25:28 1.22
@@ -55,7 +55,7 @@
*/
/*
- * $Id: DTDValidator.cpp,v 1.21 2001/09/05 20:49:10 knoaman Exp $
+ * $Id: DTDValidator.cpp,v 1.22 2001/11/13 13:25:28 tng Exp $
*/
@@ -137,20 +137,6 @@
}
-bool DTDValidator::checkRootElement(const unsigned int elemId)
-{
- //
- // If the root element was never set, then there was never a DOCTYPE. So
- // we just return false.
- //
- unsigned int fRootElemId = fDTDGrammar->getRootElemId();
- if (fRootElemId == XMLElementDecl::fgInvalidElemId)
- return false;
-
- // Else return true if our stored root element is the same as the passed one
- return (elemId == fRootElemId);
-}
-
void DTDValidator::faultInAttr(XMLAttr& toFill, const XMLAttDef& attDef) const
{
//
@@ -475,11 +461,13 @@
}
else if (reason == XMLElementDecl::AsRootElem)
{
+ // It's ok that the root element is not declared in the DTD
+ /*
emitError
(
XMLValid::UndeclaredElemInDocType
, curElem.getFullName()
- );
+ );*/
}
else if (reason == XMLElementDecl::InContentModel)
{
1.13 +3 -5 xml-xerces/c/src/validators/DTD/DTDValidator.hpp
Index: DTDValidator.hpp
===================================================================
RCS file: /home/cvs/xml-xerces/c/src/validators/DTD/DTDValidator.hpp,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -r1.12 -r1.13
--- DTDValidator.hpp 2001/06/05 16:51:20 1.12
+++ DTDValidator.hpp 2001/11/13 13:25:28 1.13
@@ -56,6 +56,9 @@
/*
* $Log: DTDValidator.hpp,v $
+ * Revision 1.13 2001/11/13 13:25:28 tng
+ * Deprecate function XMLValidator::checkRootElement.
+ *
* Revision 1.12 2001/06/05 16:51:20 knoaman
* Add 'const' to getGrammar - submitted by Peter A. Volchek.
*
@@ -139,11 +142,6 @@
XMLElementDecl* const elemDecl
, QName** const children
, const unsigned int childCount
- );
-
- virtual bool checkRootElement
- (
- const unsigned int elemId
);
virtual void faultInAttr
---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-cvs-help@xml.apache.org