Xerces-C++: XSWildcard.hpp Source File

Xerces-C++ 3.2.1

XSWildcard.hpp
Go to the documentation of this file.
1 /*
2 * Licensed to the Apache Software Foundation (ASF) under one or more
3 * contributor license agreements. See the NOTICE file distributed with
4 * this work for additional information regarding copyright ownership.
5 * The ASF licenses this file to You under the Apache License, Version 2.0
6 * (the "License"); you may not use this file except in compliance with
7 * the License. You may obtain a copy of the License at
8 *
9 * http://www.apache.org/licenses/LICENSE-2.0
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
16 */
17
18 /*
19 * $Id: XSWildcard.hpp 527149 2007-04-10 14:56:39Z amassari $
20 */
21
22 #if !defined(XERCESC_INCLUDE_GUARD_XSWILDCARD_HPP)
23 #define XERCESC_INCLUDE_GUARD_XSWILDCARD_HPP
24
25 #include <xercesc/framework/psvi/XSObject.hpp>
26
27 XERCES_CPP_NAMESPACE_BEGIN
28
36 // forward declarations
37 class XSAnnotation;
38 class SchemaAttDef;
39 class ContentSpecNode;
40
41 class XMLPARSER_EXPORT XSWildcard : public XSObject
42 {
43 public:
44
45 // Namespace Constraint
46 enum NAMESPACE_CONSTRAINT {
50 NSCONSTRAINT_ANY = 1,
54 NSCONSTRAINT_NOT = 2,
58 NSCONSTRAINT_DERIVATION_LIST = 3
59 };
60
61 // Process contents
62 enum PROCESS_CONTENTS {
67 PC_STRICT = 1,
71 PC_SKIP = 2,
78 PC_LAX = 3
79 };
80
81 // Constructors and Destructor
82 // -----------------------------------------------------------------------
85
94 XSWildcard
95 (
96 SchemaAttDef* const attWildCard
97 , XSAnnotation* const annot
98 , XSModel* const xsModel
99 , MemoryManager* const manager = XMLPlatformUtils::fgMemoryManager
100 );
101
102 XSWildcard
103 (
104 const ContentSpecNode* const elmWildCard
105 , XSAnnotation* const annot
106 , XSModel* const xsModel
107 , MemoryManager* const manager = XMLPlatformUtils::fgMemoryManager
108 );
109
111
114 ~XSWildcard();
116
117 //---------------------
121
125 NAMESPACE_CONSTRAINT getConstraintType() const;
126
133 StringList *getNsConstraintList();
134
139 PROCESS_CONTENTS getProcessContents() const;
140
144 XSAnnotation *getAnnotation() const;
145
147
148 //----------------------------------
152
154 private:
155
156 // -----------------------------------------------------------------------
157 // Unimplemented constructors and operators
158 // -----------------------------------------------------------------------
159 XSWildcard(const XSWildcard&);
160 XSWildcard & operator=(const XSWildcard &);
161
165 void buildNamespaceList(const ContentSpecNode* const rootNode);
166
167 protected:
168
169 // -----------------------------------------------------------------------
170 // data members
171 // -----------------------------------------------------------------------
172 NAMESPACE_CONSTRAINT fConstraintType;
173 PROCESS_CONTENTS fProcessContents;
174 StringList* fNsConstraintList;
175 XSAnnotation* fAnnotation;
176 };
177
178 inline XSAnnotation *XSWildcard::getAnnotation() const
179 {
180 return fAnnotation;
181 }
182
183 inline XSWildcard::PROCESS_CONTENTS XSWildcard::getProcessContents() const
184 {
185 return fProcessContents;
186 }
187
188 inline StringList* XSWildcard::getNsConstraintList()
189 {
190 return fNsConstraintList;
191 }
192
193 inline XSWildcard::NAMESPACE_CONSTRAINT XSWildcard::getConstraintType() const
194 {
195 return fConstraintType;
196 }
197
198
199 XERCES_CPP_NAMESPACE_END
200
201 #endif
XMLPlatformUtils::fgMemoryManager
static MemoryManager * fgMemoryManager
The configurable memory manager.
Definition: PlatformUtils.hpp:121
XSWildcard
Definition: XSWildcard.hpp:41
XSWildcard::fAnnotation
XSAnnotation * fAnnotation
Definition: XSWildcard.hpp:175
XSWildcard::getNsConstraintList
StringList * getNsConstraintList()
Namespace constraint.
Definition: XSWildcard.hpp:188
XSWildcard::fProcessContents
PROCESS_CONTENTS fProcessContents
Definition: XSWildcard.hpp:173
XSWildcard::fConstraintType
NAMESPACE_CONSTRAINT fConstraintType
Definition: XSWildcard.hpp:172
XSWildcard::fNsConstraintList
StringList * fNsConstraintList
Definition: XSWildcard.hpp:174
XMLPARSER_EXPORT
#define XMLPARSER_EXPORT
Definition: XercesDefs.hpp:163
XSModel
Definition: XSModel.hpp:59
XSWildcard::getAnnotation
XSAnnotation * getAnnotation() const
Optional.
Definition: XSWildcard.hpp:178
XSAnnotation
Definition: XSAnnotation.hpp:41
MemoryManager
Configurable memory manager.
Definition: MemoryManager.hpp:39
XSWildcard::getConstraintType
NAMESPACE_CONSTRAINT getConstraintType() const
Namespace constraint: A constraint type: any, not, list.
Definition: XSWildcard.hpp:193
XERCES_CPP_NAMESPACE_BEGIN
#define XERCES_CPP_NAMESPACE_BEGIN
Definition: XercesDefs.hpp:112
StringList
RefArrayVectorOf< XMLCh > StringList
Definition: XSConstants.hpp:54
XSWildcard::getProcessContents
PROCESS_CONTENTS getProcessContents() const
[process contents]: one of skip, lax or strict.
Definition: XSWildcard.hpp:183
XSObject
Definition: XSObject.hpp:42
XERCES_CPP_NAMESPACE_END
#define XERCES_CPP_NAMESPACE_END
Definition: XercesDefs.hpp:113
XSObject.hpp
XSWildcard::PROCESS_CONTENTS
PROCESS_CONTENTS
Definition: XSWildcard.hpp:62
XSWildcard::NAMESPACE_CONSTRAINT
NAMESPACE_CONSTRAINT
Definition: XSWildcard.hpp:46