ValidationContext.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: ValidationContext.hpp 568078 2007-08-21 11:43:25Z amassari $
00020  */
00021 
00022 #if !defined(VALIDATION_CONTEXT_HPP)
00023 #define VALIDATION_CONTEXT_HPP
00024 
00025 #include <xercesc/util/PlatformUtils.hpp>
00026 #include <xercesc/util/RefHashTableOf.hpp>
00027 #include <xercesc/util/NameIdPool.hpp>
00028 #include <xercesc/util/XMemory.hpp>
00029 
00030 XERCES_CPP_NAMESPACE_BEGIN
00031 
00032 class XMLRefInfo;
00033 class DTDEntityDecl;
00034 class DatatypeValidator;
00035 class ElemStack;
00036 
00037 class XMLPARSER_EXPORT ValidationContext : public XMemory
00038 {
00039 public :
00040     // -----------------------------------------------------------------------
00042     // -----------------------------------------------------------------------
00044 
00049     virtual ~ValidationContext(){};
00051 
00052     // -----------------------------------------------------------------------
00054     // -----------------------------------------------------------------------
00056 
00061     virtual RefHashTableOf<XMLRefInfo>*  getIdRefList() const = 0;
00062 
00063     virtual void                         setIdRefList(RefHashTableOf<XMLRefInfo>* const) = 0;
00064 
00065     virtual void                         clearIdRefList() = 0;
00066 
00067     virtual void                         addId(const XMLCh * const ) = 0;
00068 
00069     virtual void                         addIdRef(const XMLCh * const ) = 0;
00070 
00071     virtual void                         toCheckIdRefList(bool) = 0;
00072 
00077     virtual const NameIdPool<DTDEntityDecl>* getEntityDeclPool() const = 0;
00078 
00079     virtual const NameIdPool<DTDEntityDecl>* setEntityDeclPool(const NameIdPool<DTDEntityDecl>* const) = 0;    
00080            
00081     virtual void                             checkEntity(const XMLCh * const ) const = 0 ;
00082 
00088     virtual DatatypeValidator * getValidatingMemberType() const = 0 ;
00089     virtual void setValidatingMemberType(DatatypeValidator * validatingMemberType) = 0 ;
00090 
00095     virtual bool isPrefixUnknown(XMLCh* /* prefix */) { return true; };
00096     virtual void setElemStack(ElemStack* /* elemStack */) {};
00098 
00099    
00100 protected :
00101     // -----------------------------------------------------------------------
00103     // -----------------------------------------------------------------------
00105     ValidationContext(MemoryManager* const memMgr = XMLPlatformUtils::fgMemoryManager)
00106     :fMemoryManager(memMgr)
00107     {
00108     };
00110 
00111     // -----------------------------------------------------------------------
00112     //  Data members
00113     //
00114     //  fMemoryManager
00115     //      Pluggable memory manager for dynamic allocation/deallocation.
00116     // -----------------------------------------------------------------------
00117     MemoryManager*                    fMemoryManager;
00118 
00119 private :
00120     // -----------------------------------------------------------------------
00122     // -----------------------------------------------------------------------
00124     ValidationContext(const ValidationContext& );
00125     ValidationContext& operator=(const ValidationContext& );
00127 
00128 };
00129 
00130 XERCES_CPP_NAMESPACE_END
00131 
00132 #endif
00133 

Generated on Thu Feb 19 11:35:43 2009 for Xerces-C++ by  doxygen 1.5.4