source: trunk/VUT/GtpVisibilityPreprocessor/support/xerces/include/xercesc/validators/datatype/Base64BinaryDatatypeValidator.hpp @ 358

Revision 358, 4.5 KB checked in by bittner, 19 years ago (diff)

xerces added

RevLine 
[358]1/*
2 * Copyright 1999-2004 The Apache Software Foundation.
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 *      http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17/*
18 * $Id: Base64BinaryDatatypeValidator.hpp,v 1.10 2004/09/08 13:56:52 peiyongz Exp $
19 * $Log: Base64BinaryDatatypeValidator.hpp,v $
20 * Revision 1.10  2004/09/08 13:56:52  peiyongz
21 * Apache License Version 2.0
22 *
23 * Revision 1.9  2004/01/29 11:51:22  cargilld
24 * Code cleanup changes to get rid of various compiler diagnostic messages.
25 *
26 * Revision 1.8  2003/12/17 00:18:38  cargilld
27 * Update to memory management so that the static memory manager (one used to call Initialize) is only for static data.
28 *
29 * Revision 1.7  2003/09/30 21:31:30  peiyongz
30 * Implementation of Serialization/Deserialization
31 *
32 * Revision 1.6  2003/05/15 18:53:26  knoaman
33 * Partial implementation of the configurable memory manager.
34 *
35 * Revision 1.5  2003/01/27 19:24:17  peiyongz
36 * normalize Base64 data before checking against enumeration.
37 *
38 * Revision 1.4  2003/01/24 23:18:34  peiyongz
39 * normalizeEnumeration() added to remove optional ws in Base64 data.
40 *
41 * Revision 1.3  2002/12/18 14:17:55  gareth
42 * Fix to bug #13438. When you eant a vector that calls delete[] on its members you should use RefArrayVectorOf.
43 *
44 * Revision 1.2  2002/11/04 14:53:28  tng
45 * C++ Namespace Support.
46 *
47 * Revision 1.1.1.1  2002/02/01 22:22:40  peiyongz
48 * sane_include
49 *
50 * Revision 1.6  2001/09/24 15:33:15  peiyongz
51 * DTV Reorganization: virtual methods moved to *.cpp
52 *
53 * Revision 1.5  2001/09/19 18:49:40  peiyongz
54 * DTV reorganization: inherit from AbstractStringVaildator
55 *
56 */
57
58#if !defined(BASE64BINARY_DATATYPEVALIDATOR_HPP)
59#define BASE64BINARY_DATATYPEVALIDATOR_HPP
60
61#include <xercesc/validators/datatype/AbstractStringValidator.hpp>
62
63XERCES_CPP_NAMESPACE_BEGIN
64
65class VALIDATORS_EXPORT Base64BinaryDatatypeValidator : public AbstractStringValidator
66{
67public:
68
69    // -----------------------------------------------------------------------
70    //  Public ctor/dtor
71    // -----------------------------------------------------------------------
72        /** @name Constructors and Destructor */
73    //@{
74
75    Base64BinaryDatatypeValidator
76    (
77        MemoryManager* const manager = XMLPlatformUtils::fgMemoryManager
78    );
79    Base64BinaryDatatypeValidator
80    (
81        DatatypeValidator* const baseValidator
82        , RefHashTableOf<KVStringPair>* const facets
83        , RefArrayVectorOf<XMLCh>* const enums
84        , const int finalSet
85        , MemoryManager* const manager = XMLPlatformUtils::fgMemoryManager
86    );
87    virtual ~Base64BinaryDatatypeValidator();
88
89        //@}
90
91    /**
92      * Returns an instance of the base datatype validator class
93          * Used by the DatatypeValidatorFactory.
94      */
95    virtual DatatypeValidator* newInstance
96    (
97        RefHashTableOf<KVStringPair>* const facets
98        , RefArrayVectorOf<XMLCh>* const enums
99        , const int finalSet
100        , MemoryManager* const manager = XMLPlatformUtils::fgMemoryManager
101    );
102
103    /***
104     * Support for Serialization/De-serialization
105     ***/
106    DECL_XSERIALIZABLE(Base64BinaryDatatypeValidator)
107
108protected:
109
110    virtual void checkValueSpace(const XMLCh* const content
111                            , MemoryManager* const manager);
112
113    virtual int  getLength(const XMLCh* const content
114                       , MemoryManager* const manager) const;
115
116    virtual void normalizeEnumeration(MemoryManager* const manager);
117
118    virtual void normalizeContent(XMLCh* const, MemoryManager* const manager) const;
119
120private:
121
122    // -----------------------------------------------------------------------
123    //  Unimplemented constructors and operators
124    // -----------------------------------------------------------------------
125    Base64BinaryDatatypeValidator(const Base64BinaryDatatypeValidator&);
126    Base64BinaryDatatypeValidator& operator=(const Base64BinaryDatatypeValidator&);
127
128};
129
130XERCES_CPP_NAMESPACE_END
131
132#endif
133
134/**
135  * End of file Base64BinaryDatatypeValidator.hpp
136  */
Note: See TracBrowser for help on using the repository browser.