| API Docs for SAX and DOM |

Main Page | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members | Related Pages

# XMLDocumentHandler.hpp

Go to the documentation of this file.

    00001 /*
    00002  * Copyright 1999-2000,2004 The Apache Software Foundation.
    00003  *
    00004  * Licensed under the Apache License, Version 2.0 (the "License");
    00005  * you may not use this file except in compliance with the License.
    00006  * You may obtain a copy of the License at
    00007  *
    00008  *      http://www.apache.org/licenses/LICENSE-2.0
    00009  *
    00010  * Unless required by applicable law or agreed to in writing, software
    00011  * distributed under the License is distributed on an "AS IS" BASIS,
    00012  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    00013  * See the License for the specific language governing permissions and
    00014  * limitations under the License.
    00015  */
    00016
    00017  /*
    00018  * $Id: XMLDocumentHandler.hpp 191054 2005-06-17 02:56:35Z jberry $
    00019  */
    00020
    00021
    00022 #if !defined(XMLDOCUMENTHANDLER_HPP)
    00023 #define XMLDOCUMENTHANDLER_HPP
    00024
    00025 #include <xercesc/util/XercesDefs.hpp>
    00026 #include <xercesc/util/RefVectorOf.hpp>
    00027 #include <xercesc/framework/XMLAttr.hpp>
    00028
    00029 XERCES_CPP_NAMESPACE_BEGIN
    00030
    00031 class XMLElementDecl;
    00032 class XMLEntityDecl;
    00033
    00042 class  XMLDocumentHandler
    00043 {
    00044 public:
    00045     // -----------------------------------------------------------------------
    00046     //  Constructors are hidden, just the virtual destructor is exposed
    00047     // -----------------------------------------------------------------------
    00050     virtual ~XMLDocumentHandler()
    00051     {
    00052     }
    00054
    00077     virtual void docCharacters
    00078     (
    00079         const   XMLCh* const    chars
    00080         , const unsigned int    length
    00081         , const bool            cdataSection
    00082     ) = 0;
    00083
    00091     virtual void docComment
    00092     (
    00093         const   XMLCh* const    comment
    00094     ) = 0;
    00095
    00105     virtual void docPI
    00106     (
    00107         const   XMLCh* const    target
    00108         , const XMLCh* const    data
    00109     ) = 0;
    00110
    00118     virtual void endDocument() = 0;
    00119
    00134     virtual void endElement
    00135     (
    00136         const   XMLElementDecl& elemDecl
    00137         , const unsigned int    uriId
    00138         , const bool            isRoot
    00139         , const XMLCh* const    prefixName = 0
    00140     ) = 0;
    00141
    00149     virtual void endEntityReference
    00150     (
    00151         const   XMLEntityDecl&  entDecl
    00152     ) = 0;
    00153
    00176     virtual void ignorableWhitespace
    00177     (
    00178         const   XMLCh* const    chars
    00179         , const unsigned int    length
    00180         , const bool            cdataSection
    00181     ) = 0;
    00182
    00189     virtual void resetDocument() = 0;
    00190
    00196     virtual void startDocument() = 0;
    00197
    00215     virtual void startElement
    00216     (
    00217         const   XMLElementDecl&         elemDecl
    00218         , const unsigned int            uriId
    00219         , const XMLCh* const            prefixName
    00220         , const RefVectorOf<XMLAttr>&   attrList
    00221         , const unsigned int            attrCount
    00222         , const bool                    isEmpty
    00223         , const bool                    isRoot
    00224     ) = 0;
    00225
    00233     virtual void startEntityReference(const XMLEntityDecl& entDecl) = 0;
    00234
    00252     virtual void XMLDecl
    00253     (
    00254         const   XMLCh* const    versionStr
    00255         , const XMLCh* const    encodingStr
    00256         , const XMLCh* const    standaloneStr
    00257         , const XMLCh* const    autoEncodingStr
    00258     ) = 0;
    00259
    00279     virtual void elementTypeInfo
    00280     (
    00281         const   XMLCh* const /* typeName */
    00282         , const XMLCh* const /* typeURI */
    00283     ) { /* non pure virtual to permit backward compatibility of implementations.  */  };
    00285
    00286
    00287
    00288 protected :
    00289     // -----------------------------------------------------------------------
    00290     //  Hidden Constructors
    00291     // -----------------------------------------------------------------------
    00292     XMLDocumentHandler()
    00293     {
    00294     }
    00295
    00296
    00297 private:
    00298     // -----------------------------------------------------------------------
    00299     //  Unimplemented constructors and operators
    00300     // -----------------------------------------------------------------------
    00301     XMLDocumentHandler(const XMLDocumentHandler&);
    00302     XMLDocumentHandler& operator=(const XMLDocumentHandler&);
    00303 };
    00304
    00305 XERCES_CPP_NAMESPACE_END
    00306
    00307 #endif

Copyright © 1994-2004 The Apache Software Foundation. All Rights Reserved.