DTDHandler.h

Go to the documentation of this file.
00001 // -*- C++ -*-
00002 
00003 //=============================================================================
00004 /**
00005  *  @file    DTDHandler.h
00006  *
00007  *  DTDHandler.h,v 1.8 2005/04/20 16:22:53 ossama Exp
00008  *
00009  *  @author Nanbor Wang <nanbor@cs.wustl.edu>
00010  */
00011 //=============================================================================
00012 #ifndef _ACEXML_DTDHANDLER_H_
00013 #define _ACEXML_DTDHANDLER_H_
00014 
00015 #include /**/ "ace/pre.h"
00016 #include "ACEXML/common/ACEXML_Export.h"
00017 
00018 #if !defined (ACE_LACKS_PRAGMA_ONCE)
00019 #pragma once
00020 #endif /* ACE_LACKS_PRAGMA_ONCE */
00021 
00022 #include "ACEXML/common/Env.h"
00023 #include "ACEXML/common/SAXExceptions.h"
00024 
00025 /**
00026  * @class ACEXML_DTDHandler DTDHandler.h "ACEXML/common/DTDHandler.h"
00027  *
00028  * @brief ACEXML_DTDHandler
00029  *
00030  * If a SAX application needs information about notations and unparsed
00031  * entities, then the application implements this interface and registers
00032  * an instance with the SAX parser using the parser's setDTDHandler method.
00033  * The parser uses the instance to report notation and unparsed entity
00034  * declarations to the application.
00035  *
00036  * Note that this interface includes only those DTD events that the XML
00037  * recommendation requires processors to report: notation and unparsed
00038  * entity declarations.
00039  *
00040  * The SAX parser may report these events in any order, regardless of the
00041  * order in which the notations and unparsed entities were declared;
00042  * however, all DTD events must be reported after the document handler's
00043  * startDocument event, and before the first startElement event.
00044  *
00045  * It is up to the application to store the information for future use
00046  * (perhaps in a hash table or object tree). If the application encounters
00047  * attributes of type "NOTATION", "ENTITY", or "ENTITIES", it can use the
00048  * information that it obtained through this interface to find the entity
00049  * and/or notation corresponding with the attribute value.
00050  */
00051 class ACEXML_Export ACEXML_DTDHandler
00052 {
00053 public:
00054 
00055   virtual ~ACEXML_DTDHandler (void);
00056 
00057   /**
00058    * Receive notification of a notation declaration event.
00059    */
00060   virtual void notationDecl (const ACEXML_Char *name,
00061                              const ACEXML_Char *publicId,
00062                              const ACEXML_Char *systemId ACEXML_ENV_ARG_DECL)
00063         ACE_THROW_SPEC ((ACEXML_SAXException)) = 0;
00064 
00065   /**
00066    * Receive notification of an unparsed entity declaration event.
00067    */
00068   virtual void unparsedEntityDecl (const ACEXML_Char *name,
00069                                    const ACEXML_Char *publicId,
00070                                    const ACEXML_Char *systemId,
00071                                    const ACEXML_Char *notationName ACEXML_ENV_ARG_DECL)
00072         ACE_THROW_SPEC ((ACEXML_SAXException)) = 0;
00073 };
00074 
00075 
00076 #include /**/ "ace/post.h"
00077 
00078 #endif /* _ACEXML_DTDHANDLER_H_ */

Generated on Thu Nov 9 11:45:35 2006 for ACEXML by doxygen 1.3.6