knoaman     2002/08/14 08:20:38

  Modified:    c/src/xercesc/dom/deprecated DOMParser.cpp DOMParser.hpp
               c/src/xercesc/internal XMLScanner.cpp
               c/src/xercesc/parsers AbstractDOMParser.cpp
                        AbstractDOMParser.hpp SAX2XMLReaderImpl.cpp
                        SAX2XMLReaderImpl.hpp SAXParser.cpp SAXParser.hpp
               c/src/xercesc/validators/DTD DocTypeHandler.hpp
  Log:
  [Bug 3111] Problem with LexicalHandler::startDTD() and LexicalHandler::endDTD().
  
  Revision  Changes    Path
  1.8       +2 -1      xml-xerces/c/src/xercesc/dom/deprecated/DOMParser.cpp
  
  Index: DOMParser.cpp
  ===================================================================
  RCS file: /home/cvs/xml-xerces/c/src/xercesc/dom/deprecated/DOMParser.cpp,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- DOMParser.cpp     11 Jul 2002 18:24:30 -0000      1.7
  +++ DOMParser.cpp     14 Aug 2002 15:20:37 -0000      1.8
  @@ -961,6 +961,7 @@
       , const XMLCh* const    publicId
       , const XMLCh* const    systemId
       , const bool            hasIntSubset
  +    , const bool            hasExtSubset
   )
   {
        DOM_DocumentType dt;
  
  
  
  1.10      +2 -1      xml-xerces/c/src/xercesc/dom/deprecated/DOMParser.hpp
  
  Index: DOMParser.hpp
  ===================================================================
  RCS file: /home/cvs/xml-xerces/c/src/xercesc/dom/deprecated/DOMParser.hpp,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- DOMParser.hpp     11 Jul 2002 18:24:30 -0000      1.9
  +++ DOMParser.hpp     14 Aug 2002 15:20:37 -0000      1.10
  @@ -1501,6 +1501,7 @@
           , const XMLCh* const    publicId
           , const XMLCh* const    systemId
           , const bool            hasIntSubset
  +        , const bool            hasExtSubset = false
       );
   
       virtual void doctypePI
  
  
  
  1.19      +3 -3      xml-xerces/c/src/xercesc/internal/XMLScanner.cpp
  
  Index: XMLScanner.cpp
  ===================================================================
  RCS file: /home/cvs/xml-xerces/c/src/xercesc/internal/XMLScanner.cpp,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -r1.18 -r1.19
  --- XMLScanner.cpp    7 Aug 2002 13:18:50 -0000       1.18
  +++ XMLScanner.cpp    14 Aug 2002 15:20:38 -0000      1.19
  @@ -2457,7 +2457,7 @@
       //  call the doctype event.
       //
       if (fDocTypeHandler)
  -        fDocTypeHandler->doctypeDecl(*rootDecl, pubId, sysId, hasIntSubset);
  +        fDocTypeHandler->doctypeDecl(*rootDecl, pubId, sysId, hasIntSubset, 
hasExtSubset);
   
       //
       //  Ok, if we had an internal subset, we are just past the [ character
  @@ -4531,7 +4531,7 @@
           rootDecl->setExternalElemDeclaration(true);
           Janitor<DTDElementDecl> janSrc(rootDecl);
   
  -        fDocTypeHandler->doctypeDecl(*rootDecl, src.getPublicId(), 
src.getSystemId(), false);
  +        fDocTypeHandler->doctypeDecl(*rootDecl, src.getPublicId(), 
src.getSystemId(), false, true);
       }
   
       // Create DTDScanner
  
  
  
  1.20      +2 -1      xml-xerces/c/src/xercesc/parsers/AbstractDOMParser.cpp
  
  Index: AbstractDOMParser.cpp
  ===================================================================
  RCS file: /home/cvs/xml-xerces/c/src/xercesc/parsers/AbstractDOMParser.cpp,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -r1.19 -r1.20
  --- AbstractDOMParser.cpp     9 Aug 2002 21:30:44 -0000       1.19
  +++ AbstractDOMParser.cpp     14 Aug 2002 15:20:38 -0000      1.20
  @@ -978,6 +978,7 @@
       , const XMLCh* const    publicId
       , const XMLCh* const    systemId
       , const bool            hasIntSubset
  +    , const bool            hasExtSubset
   )
   {
       fDocumentType = (DOMDocumentTypeImpl *) 
fDocument->createDocumentType(elemDecl.getFullName(), publicId, systemId);
  
  
  
  1.11      +2 -1      xml-xerces/c/src/xercesc/parsers/AbstractDOMParser.hpp
  
  Index: AbstractDOMParser.hpp
  ===================================================================
  RCS file: /home/cvs/xml-xerces/c/src/xercesc/parsers/AbstractDOMParser.hpp,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -r1.10 -r1.11
  --- AbstractDOMParser.hpp     26 Jul 2002 20:30:48 -0000      1.10
  +++ AbstractDOMParser.hpp     14 Aug 2002 15:20:38 -0000      1.11
  @@ -1063,6 +1063,7 @@
           , const XMLCh* const    publicId
           , const XMLCh* const    systemId
           , const bool            hasIntSubset
  +        , const bool            hasExtSubset = false
       );
   
       virtual void doctypePI
  
  
  
  1.10      +9 -5      xml-xerces/c/src/xercesc/parsers/SAX2XMLReaderImpl.cpp
  
  Index: SAX2XMLReaderImpl.cpp
  ===================================================================
  RCS file: /home/cvs/xml-xerces/c/src/xercesc/parsers/SAX2XMLReaderImpl.cpp,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- SAX2XMLReaderImpl.cpp     11 Jul 2002 18:27:20 -0000      1.9
  +++ SAX2XMLReaderImpl.cpp     14 Aug 2002 15:20:38 -0000      1.10
  @@ -56,6 +56,9 @@
   
   /*
    * $Log$
  + * Revision 1.10  2002/08/14 15:20:38  knoaman
  + * [Bug 3111] Problem with LexicalHandler::startDTD() and LexicalHandler::endDTD().
  + *
    * Revision 1.9  2002/07/11 18:27:20  knoaman
    * Grammar caching/preparsing - initial implementation.
    *
  @@ -1055,12 +1058,15 @@
   void SAX2XMLReaderImpl::doctypeDecl(const   DTDElementDecl& elemDecl
                               , const XMLCh* const    publicId
                               , const XMLCh* const    systemId
  -                            , const bool            hasIntSubset)
  +                            , const bool            hasIntSubset
  +                            , const bool            hasExtSubset)
   {
  -   // Call the installed LexicalHandler.
  -   if (fLexicalHandler)
  +    // Call the installed LexicalHandler.
  +    if (fLexicalHandler && (hasIntSubset || hasExtSubset))
           fLexicalHandler->startDTD(elemDecl.getFullName(), publicId, systemId);
   
  +    fHasExternalSubset = hasExtSubset;
  +
       // Unused by SAX DTDHandler interface at this time
   }
   
  @@ -1214,8 +1220,6 @@
   
   void SAX2XMLReaderImpl::startExtSubset()
   {
  -    fHasExternalSubset = true;
  -
       if (fLexicalHandler)
           fLexicalHandler->startEntity(gDTDEntityStr);
   }
  
  
  
  1.13      +6 -0      xml-xerces/c/src/xercesc/parsers/SAX2XMLReaderImpl.hpp
  
  Index: SAX2XMLReaderImpl.hpp
  ===================================================================
  RCS file: /home/cvs/xml-xerces/c/src/xercesc/parsers/SAX2XMLReaderImpl.hpp,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- SAX2XMLReaderImpl.hpp     11 Jul 2002 18:27:04 -0000      1.12
  +++ SAX2XMLReaderImpl.hpp     14 Aug 2002 15:20:38 -0000      1.13
  @@ -56,6 +56,9 @@
   
   /*
    * $Log$
  + * Revision 1.13  2002/08/14 15:20:38  knoaman
  + * [Bug 3111] Problem with LexicalHandler::startDTD() and LexicalHandler::endDTD().
  + *
    * Revision 1.12  2002/07/11 18:27:04  knoaman
    * Grammar caching/preparsing - initial implementation.
    *
  @@ -1433,6 +1436,8 @@
         *                 system id of the DTD file.
         * @param hasIntSubset A flag indicating if this XML file contains any
         *                     internal subset.
  +      * @param hasExtSubset A flag indicating if this XML file contains any
  +      *                     external subset. Default is false.
         */
       virtual void doctypeDecl
       (
  @@ -1440,6 +1445,7 @@
           , const XMLCh* const    publicId
           , const XMLCh* const    systemId
           , const bool            hasIntSubset
  +        , const bool            hasExtSubset = false
       );
   
       /**
  
  
  
  1.8       +5 -1      xml-xerces/c/src/xercesc/parsers/SAXParser.cpp
  
  Index: SAXParser.cpp
  ===================================================================
  RCS file: /home/cvs/xml-xerces/c/src/xercesc/parsers/SAXParser.cpp,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -r1.7 -r1.8
  --- SAXParser.cpp     11 Jul 2002 18:27:04 -0000      1.7
  +++ SAXParser.cpp     14 Aug 2002 15:20:38 -0000      1.8
  @@ -56,6 +56,9 @@
   
   /*
    * $Log$
  + * Revision 1.8  2002/08/14 15:20:38  knoaman
  + * [Bug 3111] Problem with LexicalHandler::startDTD() and LexicalHandler::endDTD().
  + *
    * Revision 1.7  2002/07/11 18:27:04  knoaman
    * Grammar caching/preparsing - initial implementation.
    *
  @@ -943,7 +946,8 @@
   void SAXParser::doctypeDecl(const   DTDElementDecl& elemDecl
                               , const XMLCh* const    publicId
                               , const XMLCh* const    systemId
  -                            , const bool            hasIntSubset)
  +                            , const bool            hasIntSubset
  +                            , const bool            hasExtSubset)
   {
       // Unused by SAX DTDHandler interface at this time
   }
  
  
  
  1.13      +6 -0      xml-xerces/c/src/xercesc/parsers/SAXParser.hpp
  
  Index: SAXParser.hpp
  ===================================================================
  RCS file: /home/cvs/xml-xerces/c/src/xercesc/parsers/SAXParser.hpp,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- SAXParser.hpp     11 Jul 2002 18:27:03 -0000      1.12
  +++ SAXParser.hpp     14 Aug 2002 15:20:38 -0000      1.13
  @@ -56,6 +56,9 @@
   
   /*
    * $Log$
  + * Revision 1.13  2002/08/14 15:20:38  knoaman
  + * [Bug 3111] Problem with LexicalHandler::startDTD() and LexicalHandler::endDTD().
  + *
    * Revision 1.12  2002/07/11 18:27:03  knoaman
    * Grammar caching/preparsing - initial implementation.
    *
  @@ -1547,6 +1550,8 @@
         *                 system id of the DTD file.
         * @param hasIntSubset A flag indicating if this XML file contains any
         *                     internal subset.
  +      * @param hasExtSubset A flag indicating if this XML file contains any
  +      *                     external subset. Default is false.
         */
       virtual void doctypeDecl
       (
  @@ -1554,6 +1559,7 @@
           , const XMLCh* const    publicId
           , const XMLCh* const    systemId
           , const bool            hasIntSubset
  +        , const bool            hasExtSubset = false
       );
   
       /**
  
  
  
  1.2       +4 -0      xml-xerces/c/src/xercesc/validators/DTD/DocTypeHandler.hpp
  
  Index: DocTypeHandler.hpp
  ===================================================================
  RCS file: /home/cvs/xml-xerces/c/src/xercesc/validators/DTD/DocTypeHandler.hpp,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- DocTypeHandler.hpp        1 Feb 2002 22:22:43 -0000       1.1
  +++ DocTypeHandler.hpp        14 Aug 2002 15:20:38 -0000      1.2
  @@ -56,8 +56,11 @@
   
   /*
    * $Log$
  - * Revision 1.1  2002/02/01 22:22:43  peiyongz
  - * Initial revision
  + * Revision 1.2  2002/08/14 15:20:38  knoaman
  + * [Bug 3111] Problem with LexicalHandler::startDTD() and LexicalHandler::endDTD().
  + *
  + * Revision 1.1.1.1  2002/02/01 22:22:43  peiyongz
  + * sane_include
    *
    * Revision 1.5  2001/06/19 16:43:46  tng
    * Correct description of DocTypeHandler
  @@ -134,6 +137,7 @@
           , const XMLCh* const    publicId
           , const XMLCh* const    systemId
           , const bool            hasIntSubset
  +        , const bool            hasExtSubset = false
       ) = 0;
   
       virtual void doctypePI
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to