- Main Page
- Related Pages
- Classes
- Files

# XMLDocumentHandler.hpp

Go to the documentation of this file.

    00001 /*
    00002  * Licensed to the Apache Software Foundation (ASF) under one or more
    00003  * contributor license agreements.  See the NOTICE file distributed with
    00004  * this work for additional information regarding copyright ownership.
    00005  * The ASF licenses this file to You under the Apache License, Version 2.0
    00006  * (the "License"); you may not use this file except in compliance with
    00007  * the License.  You may obtain a copy of the License at
    00008  *
    00009  *      http://www.apache.org/licenses/LICENSE-2.0
    00010  *
    00011  * Unless required by applicable law or agreed to in writing, software
    00012  * distributed under the License is distributed on an "AS IS" BASIS,
    00013  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    00014  * See the License for the specific language governing permissions and
    00015  * limitations under the License.
    00016  */
    00017
    00018  /*
    00019  * $Id: XMLDocumentHandler.hpp 673679 2008-07-03 13:50:10Z borisk $
    00020  */
    00021
    00022 #if !defined(XERCESC_INCLUDE_GUARD_XMLDOCUMENTHANDLER_HPP)
    00023 #define XERCESC_INCLUDE_GUARD_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 XMLPARSER_EXPORT 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 XMLSize_t       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 XMLSize_t       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 XMLSize_t               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
    00261
    00262
    00263
    00264 protected :
    00265     // -----------------------------------------------------------------------
    00266     //  Hidden Constructors
    00267     // -----------------------------------------------------------------------
    00268     XMLDocumentHandler()
    00269     {
    00270     }
    00271
    00272
    00273 private:
    00274     // -----------------------------------------------------------------------
    00275     //  Unimplemented constructors and operators
    00276     // -----------------------------------------------------------------------
    00277     XMLDocumentHandler(const XMLDocumentHandler&);
    00278     XMLDocumentHandler& operator=(const XMLDocumentHandler&);
    00279 };
    00280
    00281 XERCES_CPP_NAMESPACE_END
    00282
    00283 #endif