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

SectionDescriptorReader.h

Go to the documentation of this file.
00001 //
00002 //  Copyright (c) 1996-2005 by Autodesk, Inc.
00003 //
00004 //  By using this code, you are agreeing to the terms and conditions of
00005 //  the License Agreement included in the documentation for this code.
00006 //
00007 //  AUTODESK MAKES NO WARRANTIES, EXPRESS OR IMPLIED, AS TO THE CORRECTNESS
00008 //  OF THIS CODE OR ANY DERIVATIVE WORKS WHICH INCORPORATE IT. AUTODESK
00009 //  PROVIDES THE CODE ON AN "AS-IS" BASIS AND EXPLICITLY DISCLAIMS ANY
00010 //  LIABILITY, INCLUDING CONSEQUENTIAL AND INCIDENTAL DAMAGES FOR ERRORS,
00011 //  OMISSIONS, AND OTHER PROBLEMS IN THE CODE.
00012 //
00013 //  Use, duplication, or disclosure by the U.S. Government is subject to
00014 //  restrictions set forth in FAR 52.227-19 (Commercial Computer Software
00015 //  Restricted Rights) and DFAR 252.227-7013(c)(1)(ii) (Rights in Technical
00016 //  Data and Computer Software), as applicable.
00017 //
00018 
00019 
00020 #ifndef _DWFTK_SECTION_DESCRIPTOR_READER_H
00021 #define _DWFTK_SECTION_DESCRIPTOR_READER_H
00022 
00027 
00028 #include "dwfcore/Core.h"
00029 using namespace DWFCore;
00030 
00031 
00032 #include "dwf/package/XML.h"
00033 #include "dwf/package/reader/PackageReader.h"
00034 
00035 
00036 
00037 namespace DWFToolkit
00038 {
00039 
00069 class DWFSectionDescriptorReader : public DWFXMLCallback
00070 {
00071 
00072 public:
00073 
00081     typedef enum
00082     {
00086         eProvideNone            =   0x00,
00087 
00091         eProvideAttributes      =   0x01,
00095         eProvideType            =   0x01,
00096 
00100         eProvideAll             =   0xFF
00101 
00102     } teProviderType;
00103 
00104 public:
00105 
00113     _DWFTK_API
00114     DWFSectionDescriptorReader( DWFPackageReader*   pPackageReader = NULL,
00115                                 unsigned char       nProviderFlags = eProvideAll )
00116         throw();
00117 
00123     _DWFTK_API
00124     virtual ~DWFSectionDescriptorReader()
00125         throw();
00126 
00134     _DWFTK_API
00135     DWFSectionDescriptorReader* filter() const
00136         throw();
00137 
00146     _DWFTK_API
00147     void setFilter( DWFSectionDescriptorReader* pFilter )
00148         throw();
00149 
00157     _DWFTK_API
00158     virtual bool provideType( const char*   zType )
00159         throw();
00160 
00164     _DWFTK_API
00165     virtual void notifyStartElement( const char*    zName,
00166                                      const char**   ppAttributeList )
00167         throw();
00168 
00172     _DWFTK_API
00173     virtual void notifyEndElement( const char*      zName )
00174         throw();
00175 
00179     _DWFTK_API
00180     virtual void notifyStartNamespace( const char*  zPrefix,
00181                                        const char*  zURI )
00182         throw();
00183 
00187     _DWFTK_API
00188     virtual void notifyEndNamespace( const char*    zPrefix )
00189         throw();
00190 
00194     _DWFTK_API
00195     virtual void notifyCharacterData( const char* zCData, 
00196                                       int         nLength ) 
00197         throw();
00198 
00199 protected:
00200 
00209     virtual void _provideAttributes( const char**   ppAttributeList )
00210         throw();
00211 
00212 private:
00213 
00214     void _provideType( const char* zType )
00215         throw();
00216 
00217 protected:
00218 
00223     DWFXMLElementBuilder        _oDefaultElementBuilder;
00224 
00230     DWFXMLElementBuilder*       _pElementBuilder;
00231 
00235     DWFPackageReader*           _pPackageReader;
00236 
00237 private:
00238 
00239     unsigned char               _nProviderFlags;
00240     DWFSectionDescriptorReader* _pFilter;
00241 
00242 private:
00243 
00244     //
00245     // Not implemented
00246     //
00247 
00248     DWFSectionDescriptorReader( const DWFSectionDescriptorReader& );
00249     DWFSectionDescriptorReader& operator=( const DWFSectionDescriptorReader& );
00250 };
00251 
00252 
00253 
00254 }
00255 
00256 #endif

Generated on Tue May 17 12:38:51 2005 for Autodesk DWF Toolkit by  doxygen 1.4.1