2 * Licensed to the University Corporation for Advanced Internet
3 * Development, Inc. (UCAID) under one or more contributor license
4 * agreements. See the NOTICE file distributed with this work for
5 * additional information regarding copyright ownership.
7 * UCAID licenses this file to you under the Apache License,
8 * Version 2.0 (the "License"); you may not use this file except
9 * in compliance with the License. You may obtain a copy of the
12 * http://www.apache.org/licenses/LICENSE-2.0
14 * Unless required by applicable law or agreed to in writing,
15 * software distributed under the License is distributed on an
16 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
17 * either express or implied. See the License for the specific
18 * language governing permissions and limitations under the License.
22 * @file xmltooling/base.h
24 * Base header file definitions.
25 * Must be included prior to including any other header.
28 #ifndef __xmltooling_base_h__
29 #define __xmltooling_base_h__
33 /* Required for sprintf, used by integer XML attribute macros. */
36 #if defined (_MSC_VER) || defined(__BORLANDC__)
37 #include <xmltooling/config_pub_win32.h>
39 #include <xmltooling/config_pub.h>
42 #ifdef XMLTOOLING_LITE
43 # define XMLTOOLING_NO_XMLSEC 1
50 #if defined(XMLTOOLING_NO_XMLSEC) || !defined(HAVE_XSECSIZE_T)
51 # ifdef XMLTOOLING_XERCESC_64BITSAFE
52 # include <xercesc/util/XercesDefs.hpp>
53 typedef XMLSize_t xsecsize_t;
55 typedef unsigned int xsecsize_t;
59 // Windows and GCC4 Symbol Visibility Macros
61 #define XMLTOOL_IMPORT __declspec(dllimport)
62 #define XMLTOOL_EXPORT __declspec(dllexport)
63 #define XMLTOOL_DLLLOCAL
64 #define XMLTOOL_DLLPUBLIC
66 #define XMLTOOL_IMPORT
67 #ifdef GCC_HASCLASSVISIBILITY
68 #define XMLTOOL_EXPORT __attribute__ ((visibility("default")))
69 #define XMLTOOL_DLLLOCAL __attribute__ ((visibility("hidden")))
70 #define XMLTOOL_DLLPUBLIC __attribute__ ((visibility("default")))
72 #define XMLTOOL_EXPORT
73 #define XMLTOOL_DLLLOCAL
74 #define XMLTOOL_DLLPUBLIC
78 // Define XMLTOOL_API for DLL builds
79 #ifdef XMLTOOLING_EXPORTS
80 #define XMLTOOL_API XMLTOOL_EXPORT
82 #define XMLTOOL_API XMLTOOL_IMPORT
85 // Throwable classes must always be visible on GCC in all binaries
87 #define XMLTOOL_EXCEPTIONAPI(api) api
88 #elif defined(GCC_HASCLASSVISIBILITY)
89 #define XMLTOOL_EXCEPTIONAPI(api) XMLTOOL_EXPORT
91 #define XMLTOOL_EXCEPTIONAPI(api)
95 #define XMLTOOLING_DOXYGEN(desc) /##** desc */
97 #define XMLTOOLING_DOXYGEN(desc)
101 * Blocks copy c'tor and assignment operator for a class.
103 #define MAKE_NONCOPYABLE(type) \
106 type& operator=(const type&)
112 #define UNICODE_LITERAL_1(a) {xercesc::chLatin_##a, xercesc::chNull}
113 #define UNICODE_LITERAL_2(a,b) {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chNull}
114 #define UNICODE_LITERAL_3(a,b,c) {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chNull}
115 #define UNICODE_LITERAL_4(a,b,c,d) {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chNull}
116 #define UNICODE_LITERAL_5(a,b,c,d,e) \
117 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chNull}
118 #define UNICODE_LITERAL_6(a,b,c,d,e,f) \
119 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chNull}
120 #define UNICODE_LITERAL_7(a,b,c,d,e,f,g) \
121 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chNull}
122 #define UNICODE_LITERAL_8(a,b,c,d,e,f,g,h) \
123 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chNull}
124 #define UNICODE_LITERAL_9(a,b,c,d,e,f,g,h,i) \
125 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, xercesc::chNull}
126 #define UNICODE_LITERAL_10(a,b,c,d,e,f,g,h,i,j) \
127 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
128 xercesc::chLatin_##j, xercesc::chNull}
129 #define UNICODE_LITERAL_11(a,b,c,d,e,f,g,h,i,j,k) \
130 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
131 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chNull}
132 #define UNICODE_LITERAL_12(a,b,c,d,e,f,g,h,i,j,k,l) \
133 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
134 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chNull}
135 #define UNICODE_LITERAL_13(a,b,c,d,e,f,g,h,i,j,k,l,m) \
136 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
137 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chNull}
138 #define UNICODE_LITERAL_14(a,b,c,d,e,f,g,h,i,j,k,l,m,n) \
139 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
140 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chNull}
141 #define UNICODE_LITERAL_15(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o) \
142 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
143 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chNull}
144 #define UNICODE_LITERAL_16(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p) \
145 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
146 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chNull}
147 #define UNICODE_LITERAL_17(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q) \
148 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
149 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chNull}
150 #define UNICODE_LITERAL_18(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r) \
151 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
152 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, xercesc::chNull}
153 #define UNICODE_LITERAL_19(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s) \
154 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
155 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
156 xercesc::chLatin_##s, xercesc::chNull}
157 #define UNICODE_LITERAL_20(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t) \
158 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
159 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
160 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chNull}
161 #define UNICODE_LITERAL_21(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u) \
162 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
163 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
164 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chNull}
165 #define UNICODE_LITERAL_22(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v) \
166 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
167 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
168 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chNull}
169 #define UNICODE_LITERAL_23(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w) \
170 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
171 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
172 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chNull}
173 #define UNICODE_LITERAL_24(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x) \
174 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
175 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
176 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chNull}
177 #define UNICODE_LITERAL_25(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y) \
178 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
179 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
180 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chNull}
181 #define UNICODE_LITERAL_26(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z) \
182 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
183 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
184 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, xercesc::chNull}
185 #define UNICODE_LITERAL_27(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa) \
186 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
187 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
188 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
189 xercesc::chLatin_##aa, xercesc::chNull}
190 #define UNICODE_LITERAL_28(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb) \
191 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
192 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
193 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
194 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chNull}
195 #define UNICODE_LITERAL_29(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc) \
196 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
197 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
198 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
199 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chNull}
200 #define UNICODE_LITERAL_30(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd) \
201 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
202 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
203 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
204 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chNull}
205 #define UNICODE_LITERAL_31(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee) \
206 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
207 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
208 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
209 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chNull}
210 #define UNICODE_LITERAL_32(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff) \
211 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
212 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
213 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
214 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chLatin_##ff, xercesc::chNull}
215 #define UNICODE_LITERAL_33(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff,gg) \
216 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
217 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
218 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
219 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chLatin_##ff, xercesc::chLatin_##gg, xercesc::chNull}
220 #define UNICODE_LITERAL_34(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff,gg,hh) \
221 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
222 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
223 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
224 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chLatin_##ff, xercesc::chLatin_##gg, xercesc::chLatin_##hh, xercesc::chNull}
225 #define UNICODE_LITERAL_35(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff,gg,hh,ii) \
226 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
227 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
228 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
229 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chLatin_##ff, xercesc::chLatin_##gg, xercesc::chLatin_##hh, \
230 xercesc::chLatin_##ii, xercesc::chNull}
231 #define UNICODE_LITERAL_36(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff,gg,hh,ii,jj) \
232 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
233 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
234 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
235 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chLatin_##ff, xercesc::chLatin_##gg, xercesc::chLatin_##hh, \
236 xercesc::chLatin_##ii, xercesc::chLatin_##jj, xercesc::chNull}
237 #define UNICODE_LITERAL_37(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff,gg,hh,ii,jj,kk) \
238 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
239 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
240 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
241 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chLatin_##ff, xercesc::chLatin_##gg, xercesc::chLatin_##hh, \
242 xercesc::chLatin_##ii, xercesc::chLatin_##jj, xercesc::chLatin_##kk, xercesc::chNull}
243 #define UNICODE_LITERAL_38(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff,gg,hh,ii,jj,kk,ll) \
244 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
245 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
246 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
247 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chLatin_##ff, xercesc::chLatin_##gg, xercesc::chLatin_##hh, \
248 xercesc::chLatin_##ii, xercesc::chLatin_##jj, xercesc::chLatin_##kk, xercesc::chLatin_##ll, xercesc::chNull}
249 #define UNICODE_LITERAL_39(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff,gg,hh,ii,jj,kk,ll,mm) \
250 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
251 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
252 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
253 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chLatin_##ff, xercesc::chLatin_##gg, xercesc::chLatin_##hh, \
254 xercesc::chLatin_##ii, xercesc::chLatin_##jj, xercesc::chLatin_##kk, xercesc::chLatin_##ll, xercesc::chLatin_##mm, xercesc::chNull}
255 #define UNICODE_LITERAL_40(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff,gg,hh,ii,jj,kk,ll,mm,nn) \
256 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
257 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
258 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
259 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chLatin_##ff, xercesc::chLatin_##gg, xercesc::chLatin_##hh, \
260 xercesc::chLatin_##ii, xercesc::chLatin_##jj, xercesc::chLatin_##kk, xercesc::chLatin_##ll, xercesc::chLatin_##mm, xercesc::chLatin_##nn, xercesc::chNull}
261 #define UNICODE_LITERAL_41(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff,gg,hh,ii,jj,kk,ll,mm,nn,oo) \
262 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
263 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
264 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
265 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chLatin_##ff, xercesc::chLatin_##gg, xercesc::chLatin_##hh, \
266 xercesc::chLatin_##ii, xercesc::chLatin_##jj, xercesc::chLatin_##kk, xercesc::chLatin_##ll, xercesc::chLatin_##mm, xercesc::chLatin_##nn, xercesc::chLatin_##oo, xercesc::chNull}
267 #define UNICODE_LITERAL_42(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff,gg,hh,ii,jj,kk,ll,mm,nn,oo,pp) \
268 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
269 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
270 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
271 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chLatin_##ff, xercesc::chLatin_##gg, xercesc::chLatin_##hh, \
272 xercesc::chLatin_##ii, xercesc::chLatin_##jj, xercesc::chLatin_##kk, xercesc::chLatin_##ll, xercesc::chLatin_##mm, xercesc::chLatin_##nn, xercesc::chLatin_##oo, xercesc::chLatin_##pp, xercesc::chNull}
273 #define UNICODE_LITERAL_43(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff,gg,hh,ii,jj,kk,ll,mm,nn,oo,pp,qq) \
274 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
275 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
276 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
277 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chLatin_##ff, xercesc::chLatin_##gg, xercesc::chLatin_##hh, \
278 xercesc::chLatin_##ii, xercesc::chLatin_##jj, xercesc::chLatin_##kk, xercesc::chLatin_##ll, xercesc::chLatin_##mm, xercesc::chLatin_##nn, xercesc::chLatin_##oo, xercesc::chLatin_##pp, \
279 xercesc::chLatin_##qq, xercesc::chNull}
280 #define UNICODE_LITERAL_44(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff,gg,hh,ii,jj,kk,ll,mm,nn,oo,pp,qq,rr) \
281 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
282 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
283 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
284 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chLatin_##ff, xercesc::chLatin_##gg, xercesc::chLatin_##hh, \
285 xercesc::chLatin_##ii, xercesc::chLatin_##jj, xercesc::chLatin_##kk, xercesc::chLatin_##ll, xercesc::chLatin_##mm, xercesc::chLatin_##nn, xercesc::chLatin_##oo, xercesc::chLatin_##pp, \
286 xercesc::chLatin_##qq, xercesc::chLatin_##rr, xercesc::chNull}
287 #define UNICODE_LITERAL_45(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff,gg,hh,ii,jj,kk,ll,mm,nn,oo,pp,qq,rr,ss) \
288 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
289 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
290 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
291 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chLatin_##ff, xercesc::chLatin_##gg, xercesc::chLatin_##hh, \
292 xercesc::chLatin_##ii, xercesc::chLatin_##jj, xercesc::chLatin_##kk, xercesc::chLatin_##ll, xercesc::chLatin_##mm, xercesc::chLatin_##nn, xercesc::chLatin_##oo, xercesc::chLatin_##pp, \
293 xercesc::chLatin_##qq, xercesc::chLatin_##rr, xercesc::chLatin_##ss, xercesc::chNull}
294 #define UNICODE_LITERAL_46(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff,gg,hh,ii,jj,kk,ll,mm,nn,oo,pp,qq,rr,ss,tt) \
295 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
296 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
297 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
298 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chLatin_##ff, xercesc::chLatin_##gg, xercesc::chLatin_##hh, \
299 xercesc::chLatin_##ii, xercesc::chLatin_##jj, xercesc::chLatin_##kk, xercesc::chLatin_##ll, xercesc::chLatin_##mm, xercesc::chLatin_##nn, xercesc::chLatin_##oo, xercesc::chLatin_##pp, \
300 xercesc::chLatin_##qq, xercesc::chLatin_##rr, xercesc::chLatin_##ss, xercesc::chLatin_##tt, xercesc::chNull}
301 #define UNICODE_LITERAL_47(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff,gg,hh,ii,jj,kk,ll,mm,nn,oo,pp,qq,rr,ss,tt,uu) \
302 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
303 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
304 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
305 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chLatin_##ff, xercesc::chLatin_##gg, xercesc::chLatin_##hh, \
306 xercesc::chLatin_##ii, xercesc::chLatin_##jj, xercesc::chLatin_##kk, xercesc::chLatin_##ll, xercesc::chLatin_##mm, xercesc::chLatin_##nn, xercesc::chLatin_##oo, xercesc::chLatin_##pp, \
307 xercesc::chLatin_##qq, xercesc::chLatin_##rr, xercesc::chLatin_##ss, xercesc::chLatin_##tt, xercesc::chLatin_##uu, xercesc::chNull}
308 #define UNICODE_LITERAL_48(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff,gg,hh,ii,jj,kk,ll,mm,nn,oo,pp,qq,rr,ss,tt,uu,vv) \
309 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
310 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
311 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
312 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chLatin_##ff, xercesc::chLatin_##gg, xercesc::chLatin_##hh, \
313 xercesc::chLatin_##ii, xercesc::chLatin_##jj, xercesc::chLatin_##kk, xercesc::chLatin_##ll, xercesc::chLatin_##mm, xercesc::chLatin_##nn, xercesc::chLatin_##oo, xercesc::chLatin_##pp, \
314 xercesc::chLatin_##qq, xercesc::chLatin_##rr, xercesc::chLatin_##ss, xercesc::chLatin_##tt, xercesc::chLatin_##uu, xercesc::chLatin_##vv, xercesc::chNull}
315 #define UNICODE_LITERAL_49(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff,gg,hh,ii,jj,kk,ll,mm,nn,oo,pp,qq,rr,ss,tt,uu,vv,ww) \
316 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
317 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
318 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
319 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chLatin_##ff, xercesc::chLatin_##gg, xercesc::chLatin_##hh, \
320 xercesc::chLatin_##ii, xercesc::chLatin_##jj, xercesc::chLatin_##kk, xercesc::chLatin_##ll, xercesc::chLatin_##mm, xercesc::chLatin_##nn, xercesc::chLatin_##oo, xercesc::chLatin_##pp, \
321 xercesc::chLatin_##qq, xercesc::chLatin_##rr, xercesc::chLatin_##ss, xercesc::chLatin_##tt, xercesc::chLatin_##uu, xercesc::chLatin_##vv, xercesc::chLatin_##ww, xercesc::chNull}
322 #define UNICODE_LITERAL_50(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff,gg,hh,ii,jj,kk,ll,mm,nn,oo,pp,qq,rr,ss,tt,uu,vv,ww,xx) \
323 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
324 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
325 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
326 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chLatin_##ff, xercesc::chLatin_##gg, xercesc::chLatin_##hh, \
327 xercesc::chLatin_##ii, xercesc::chLatin_##jj, xercesc::chLatin_##kk, xercesc::chLatin_##ll, xercesc::chLatin_##mm, xercesc::chLatin_##nn, xercesc::chLatin_##oo, xercesc::chLatin_##pp, \
328 xercesc::chLatin_##qq, xercesc::chLatin_##rr, xercesc::chLatin_##ss, xercesc::chLatin_##tt, xercesc::chLatin_##uu, xercesc::chLatin_##vv, xercesc::chLatin_##ww, xercesc::chLatin_##xx, xercesc::chNull}
329 #define UNICODE_LITERAL_51(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff,gg,hh,ii,jj,kk,ll,mm,nn,oo,pp,qq,rr,ss,tt,uu,vv,ww,xx,yy) \
330 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
331 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
332 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
333 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chLatin_##ff, xercesc::chLatin_##gg, xercesc::chLatin_##hh, \
334 xercesc::chLatin_##ii, xercesc::chLatin_##jj, xercesc::chLatin_##kk, xercesc::chLatin_##ll, xercesc::chLatin_##mm, xercesc::chLatin_##nn, xercesc::chLatin_##oo, xercesc::chLatin_##pp, \
335 xercesc::chLatin_##qq, xercesc::chLatin_##rr, xercesc::chLatin_##ss, xercesc::chLatin_##tt, xercesc::chLatin_##uu, xercesc::chLatin_##vv, xercesc::chLatin_##ww, xercesc::chLatin_##xx, \
336 xercesc::chLatin_##yy, xercesc::chNull}
337 #define UNICODE_LITERAL_52(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff,gg,hh,ii,jj,kk,ll,mm,nn,oo,pp,qq,rr,ss,tt,uu,vv,ww,xx,yy,zz) \
338 {xercesc::chLatin_##a, xercesc::chLatin_##b, xercesc::chLatin_##c, xercesc::chLatin_##d, xercesc::chLatin_##e, xercesc::chLatin_##f, xercesc::chLatin_##g, xercesc::chLatin_##h, xercesc::chLatin_##i, \
339 xercesc::chLatin_##j, xercesc::chLatin_##k, xercesc::chLatin_##l, xercesc::chLatin_##m, xercesc::chLatin_##n, xercesc::chLatin_##o, xercesc::chLatin_##p, xercesc::chLatin_##q, xercesc::chLatin_##r, \
340 xercesc::chLatin_##s, xercesc::chLatin_##t, xercesc::chLatin_##u, xercesc::chLatin_##v, xercesc::chLatin_##w, xercesc::chLatin_##x, xercesc::chLatin_##y, xercesc::chLatin_##z, \
341 xercesc::chLatin_##aa, xercesc::chLatin_##bb, xercesc::chLatin_##cc, xercesc::chLatin_##dd, xercesc::chLatin_##ee, xercesc::chLatin_##ff, xercesc::chLatin_##gg, xercesc::chLatin_##hh, \
342 xercesc::chLatin_##ii, xercesc::chLatin_##jj, xercesc::chLatin_##kk, xercesc::chLatin_##ll, xercesc::chLatin_##mm, xercesc::chLatin_##nn, xercesc::chLatin_##oo, xercesc::chLatin_##pp, \
343 xercesc::chLatin_##qq, xercesc::chLatin_##rr, xercesc::chLatin_##ss, xercesc::chLatin_##tt, xercesc::chLatin_##uu, xercesc::chLatin_##vv, xercesc::chLatin_##ww, xercesc::chLatin_##xx, \
344 xercesc::chLatin_##yy, xercesc::chLatin_##zz, xercesc::chNull}
345 #endif /* DOXYGEN_SKIP */
348 * Begins the declaration of an XMLObject specialization for an abstract element/type.
349 * Basic boilerplate includes a protected constructor, empty virtual destructor,
350 * and Unicode constants for the default associated element's name and prefix.
352 * @param linkage linkage specifier for the class
353 * @param cname the name of the class to declare
354 * @param base the base class to derive from using public virtual inheritance
355 * @param desc documentation comment for class
357 #define DECL_XMLOBJECT_ABSTRACT(linkage,cname,base,desc) \
358 XMLTOOLING_DOXYGEN(desc) \
359 class linkage cname : public virtual base { \
363 virtual ~cname() {} \
364 XMLTOOLING_DOXYGEN(Element local name) \
365 static const XMLCh LOCAL_NAME[]; \
369 * Begins the declaration of an XMLObject specialization.
370 * Basic boilerplate includes a protected constructor, empty virtual destructor,
371 * and Unicode constants for the default associated element's name and prefix.
373 * @param linkage linkage specifier for the class
374 * @param cname the name of the class to declare
375 * @param base the base class to derive from using public virtual inheritance
376 * @param desc documentation comment for class
378 #define BEGIN_XMLOBJECT(linkage,cname,base,desc) \
379 XMLTOOLING_DOXYGEN(desc) \
380 class linkage cname : public virtual base { \
384 virtual ~cname() {} \
385 XMLTOOLING_DOXYGEN(Type-specific clone method.) \
386 virtual cname* clone##cname() const=0; \
387 XMLTOOLING_DOXYGEN(Element local name) \
388 static const XMLCh LOCAL_NAME[]
391 * Begins the declaration of an XMLObject specialization with two base classes.
392 * Basic boilerplate includes a protected constructor, empty virtual destructor,
393 * and Unicode constants for the default associated element's name and prefix.
395 * @param linkage linkage specifier for the class
396 * @param cname the name of the class to declare
397 * @param base the first base class to derive from using public virtual inheritance
398 * @param base2 the second base class to derive from using public virtual inheritance
399 * @param desc documentation comment for class
401 #define BEGIN_XMLOBJECT2(linkage,cname,base,base2,desc) \
402 XMLTOOLING_DOXYGEN(desc) \
403 class linkage cname : public virtual base, public virtual base2 { \
407 virtual ~cname() {} \
408 XMLTOOLING_DOXYGEN(Type-specific clone method.) \
409 virtual cname* clone##cname() const=0; \
410 XMLTOOLING_DOXYGEN(Element local name) \
411 static const XMLCh LOCAL_NAME[]
414 * Begins the declaration of an XMLObject specialization with three base classes.
415 * Basic boilerplate includes a protected constructor, empty virtual destructor,
416 * and Unicode constants for the default associated element's name and prefix.
418 * @param linkage linkage specifier for the class
419 * @param cname the name of the class to declare
420 * @param base the first base class to derive from using public virtual inheritance
421 * @param base2 the second base class to derive from using public virtual inheritance
422 * @param base3 the third base class to derive from using public virtual inheritance
423 * @param desc documentation comment for class
425 #define BEGIN_XMLOBJECT3(linkage,cname,base,base2,base3,desc) \
426 XMLTOOLING_DOXYGEN(desc) \
427 class linkage cname : public virtual base, public virtual base2, public virtual base3 { \
431 virtual ~cname() {} \
432 XMLTOOLING_DOXYGEN(Type-specific clone method.) \
433 virtual cname* clone##cname() const=0; \
434 XMLTOOLING_DOXYGEN(Element local name) \
435 static const XMLCh LOCAL_NAME[]
438 * Begins the declaration of an XMLObject specialization with four base classes.
439 * Basic boilerplate includes a protected constructor, empty virtual destructor,
440 * and Unicode constants for the default associated element's name and prefix.
442 * @param linkage linkage specifier for the class
443 * @param cname the name of the class to declare
444 * @param base the first base class to derive from using public virtual inheritance
445 * @param base2 the second base class to derive from using public virtual inheritance
446 * @param base3 the third base class to derive from using public virtual inheritance
447 * @param base4 the fourth base class to derive from using public virtual inheritance
448 * @param desc documentation comment for class
450 #define BEGIN_XMLOBJECT4(linkage,cname,base,base2,base3,base4,desc) \
451 XMLTOOLING_DOXYGEN(desc) \
452 class linkage cname : public virtual base, public virtual base2, public virtual base3, public virtual base4 { \
456 virtual ~cname() {} \
457 XMLTOOLING_DOXYGEN(Type-specific clone method.) \
458 virtual cname* clone##cname() const=0; \
459 XMLTOOLING_DOXYGEN(Element local name) \
460 static const XMLCh LOCAL_NAME[]
463 * Begins the declaration of an XMLObject specialization with five base classes.
464 * Basic boilerplate includes a protected constructor, empty virtual destructor,
465 * and Unicode constants for the default associated element's name and prefix.
467 * @param linkage linkage specifier for the class
468 * @param cname the name of the class to declare
469 * @param base the first base class to derive from using public virtual inheritance
470 * @param base2 the second base class to derive from using public virtual inheritance
471 * @param base3 the third base class to derive from using public virtual inheritance
472 * @param base4 the fourth base class to derive from using public virtual inheritance
473 * @param base5 the fifth base class to derive from using public virtual inheritance
474 * @param desc documentation comment for class
476 #define BEGIN_XMLOBJECT5(linkage,cname,base,base2,base3,base4,base5,desc) \
477 XMLTOOLING_DOXYGEN(desc) \
478 class linkage cname : public virtual base, public virtual base2, public virtual base3, public virtual base4, public virtual base5 { \
482 virtual ~cname() {} \
483 XMLTOOLING_DOXYGEN(Type-specific clone method.) \
484 virtual cname* clone##cname() const=0; \
485 XMLTOOLING_DOXYGEN(Element local name) \
486 static const XMLCh LOCAL_NAME[]
489 * Ends the declaration of an XMLObject specialization.
491 #define END_XMLOBJECT }
494 * Declares a static variable holding the XMLObject's element QName.
496 #define DECL_ELEMENT_QNAME \
498 XMLTOOLING_DOXYGEN(Element QName) \
499 static xmltooling::QName ELEMENT_QNAME
502 * Declares a static variable holding the XMLObject's schema type QName.
504 #define DECL_TYPE_QNAME \
506 XMLTOOLING_DOXYGEN(Type QName) \
507 static xmltooling::QName TYPE_QNAME
510 * Implements a static variable holding an XMLObject's element QName.
512 * @param cname the name of the XMLObject specialization
513 * @param namespaceURI the XML namespace of the default associated element
514 * @param namespacePrefix the XML namespace prefix of the default associated element
516 #define IMPL_ELEMENT_QNAME(cname,namespaceURI,namespacePrefix) \
517 xmltooling::QName cname::ELEMENT_QNAME(namespaceURI,cname::LOCAL_NAME,namespacePrefix)
520 * Implements a static variable holding an XMLObject's schema type QName.
522 * @param cname the name of the XMLObject specialization
523 * @param namespaceURI the XML namespace of the default associated element
524 * @param namespacePrefix the XML namespace prefix of the default associated element
526 #define IMPL_TYPE_QNAME(cname,namespaceURI,namespacePrefix) \
527 xmltooling::QName cname::TYPE_QNAME(namespaceURI,cname::TYPE_NAME,namespacePrefix)
530 * Declares abstract set method for a typed XML attribute.
531 * The get method is omitted.
533 * @param proper the proper name of the attribute
534 * @param upcased the upcased name of the attribute
535 * @param type the attribute's data type
537 #define DECL_INHERITED_XMLOBJECT_ATTRIB(proper,upcased,type) \
539 XMLTOOLING_DOXYGEN(proper attribute name) \
540 static const XMLCh upcased##_ATTRIB_NAME[]; \
541 XMLTOOLING_DOXYGEN(Sets the proper attribute.) \
542 virtual void set##proper(const type* proper)=0
545 * Declares abstract get/set methods for a typed XML attribute.
547 * @param proper the proper name of the attribute
548 * @param upcased the upcased name of the attribute
549 * @param type the attribute's data type
551 #define DECL_XMLOBJECT_ATTRIB(proper,upcased,type) \
553 XMLTOOLING_DOXYGEN(proper attribute name) \
554 static const XMLCh upcased##_ATTRIB_NAME[]; \
555 XMLTOOLING_DOXYGEN(Returns the proper attribute.) \
556 virtual const type* get##proper() const=0; \
557 XMLTOOLING_DOXYGEN(Sets the proper attribute.) \
558 virtual void set##proper(const type* proper)=0
561 * Declares abstract set method for a string XML attribute.
562 * The get method is omitted.
564 * @param proper the proper name of the attribute
565 * @param upcased the upcased name of the attribute
567 #define DECL_INHERITED_STRING_ATTRIB(proper,upcased) \
568 DECL_INHERITED_XMLOBJECT_ATTRIB(proper,upcased,XMLCh)
571 * Declares abstract get/set methods for a string XML attribute.
573 * @param proper the proper name of the attribute
574 * @param upcased the upcased name of the attribute
576 #define DECL_STRING_ATTRIB(proper,upcased) \
577 DECL_XMLOBJECT_ATTRIB(proper,upcased,XMLCh)
580 * Declares abstract set method for a DateTime XML attribute.
581 * The get method is omitted.
583 * @param proper the proper name of the attribute
584 * @param upcased the upcased name of the attribute
586 #define DECL_INHERITED_DATETIME_ATTRIB(proper,upcased) \
587 DECL_INHERITED_XMLOBJECT_ATTRIB(proper,upcased,xmltooling::DateTime); \
588 XMLTOOLING_DOXYGEN(Sets the proper attribute.) \
589 virtual void set##proper(time_t proper)=0; \
590 XMLTOOLING_DOXYGEN(Sets the proper attribute.) \
591 virtual void set##proper(const XMLCh* proper)=0
594 * Declares abstract get/set methods for a DateTime XML attribute.
596 * @param proper the proper name of the attribute
597 * @param upcased the upcased name of the attribute
599 #define DECL_DATETIME_ATTRIB(proper,upcased) \
600 DECL_XMLOBJECT_ATTRIB(proper,upcased,xmltooling::DateTime); \
601 XMLTOOLING_DOXYGEN(Returns the proper attribute in epoch form.) \
602 virtual time_t get##proper##Epoch() const=0; \
603 XMLTOOLING_DOXYGEN(Sets the proper attribute.) \
604 virtual void set##proper(time_t proper)=0; \
605 XMLTOOLING_DOXYGEN(Sets the proper attribute.) \
606 virtual void set##proper(const XMLCh* proper)=0
609 * Declares abstract set method for an integer XML attribute.
610 * The get method is omitted.
612 * @param proper the proper name of the attribute
613 * @param upcased the upcased name of the attribute
615 #define DECL_INHERITED_INTEGER_ATTRIB(proper,upcased) \
617 XMLTOOLING_DOXYGEN(proper attribute name) \
618 static const XMLCh upcased##_ATTRIB_NAME[]; \
619 XMLTOOLING_DOXYGEN(Sets the proper attribute using a string value.) \
620 virtual void set##proper(const XMLCh* proper)=0; \
621 XMLTOOLING_DOXYGEN(Sets the proper attribute.) \
622 virtual void set##proper(int proper)=0
625 * Declares abstract get/set methods for an integer XML attribute.
627 * @param proper the proper name of the attribute
628 * @param upcased the upcased name of the attribute
630 #define DECL_INTEGER_ATTRIB(proper,upcased) \
632 XMLTOOLING_DOXYGEN(proper attribute name) \
633 static const XMLCh upcased##_ATTRIB_NAME[]; \
634 XMLTOOLING_DOXYGEN(Returns the proper attribute after a NULL indicator.) \
635 virtual std::pair<bool,int> get##proper() const=0; \
636 XMLTOOLING_DOXYGEN(Sets the proper attribute using a string value.) \
637 virtual void set##proper(const XMLCh* proper)=0; \
638 XMLTOOLING_DOXYGEN(Sets the proper attribute.) \
639 virtual void set##proper(int proper)=0
642 * Declares abstract get/set methods for a boolean XML attribute.
644 * @param proper the proper name of the attribute
645 * @param upcased the upcased name of the attribute
646 * @param def the default/presumed value, if no explicit value has been set
648 #define DECL_BOOLEAN_ATTRIB(proper,upcased,def) \
650 XMLTOOLING_DOXYGEN(proper attribute name) \
651 static const XMLCh upcased##_ATTRIB_NAME[]; \
652 XMLTOOLING_DOXYGEN(Returns the proper attribute or def if not set.) \
653 bool proper() const { \
654 switch (get##proper()) { \
655 case xmlconstants::XML_BOOL_TRUE: \
656 case xmlconstants::XML_BOOL_ONE: \
658 case xmlconstants::XML_BOOL_FALSE: \
659 case xmlconstants::XML_BOOL_ZERO: \
665 XMLTOOLING_DOXYGEN(Returns the proper attribute as an explicit enumerated value.) \
666 virtual xmlconstants::xmltooling_bool_t get##proper() const=0; \
667 XMLTOOLING_DOXYGEN(Sets the proper attribute using an enumerated value.) \
668 virtual void proper(xmlconstants::xmltooling_bool_t value)=0; \
669 XMLTOOLING_DOXYGEN(Sets the proper attribute.) \
670 void proper(bool value) { \
671 proper(value ? xmlconstants::XML_BOOL_ONE : xmlconstants::XML_BOOL_ZERO); \
673 XMLTOOLING_DOXYGEN(Sets the proper attribute using a string constant.) \
674 void set##proper(const XMLCh* value) { \
677 case xercesc::chLatin_t: \
678 proper(xmlconstants::XML_BOOL_TRUE); \
680 case xercesc::chLatin_f: \
681 proper(xmlconstants::XML_BOOL_FALSE); \
683 case xercesc::chDigit_1: \
684 proper(xmlconstants::XML_BOOL_ONE); \
686 case xercesc::chDigit_0: \
687 proper(xmlconstants::XML_BOOL_ZERO); \
690 proper(xmlconstants::XML_BOOL_NULL); \
694 proper(xmlconstants::XML_BOOL_NULL); \
698 * Implements get/set methods and a private member for a typed XML attribute.
700 * @param proper the proper name of the attribute
701 * @param type the attribute's data type
703 #define IMPL_XMLOBJECT_ATTRIB(proper,type) \
707 const type* get##proper() const { \
710 void set##proper(const type* proper) { \
711 m_##proper = prepareForAssignment(m_##proper,proper); \
715 * Implements get/set methods and a private member for a string XML attribute.
717 * @param proper the proper name of the attribute
719 #define IMPL_STRING_ATTRIB(proper) \
720 IMPL_XMLOBJECT_ATTRIB(proper,XMLCh)
723 * Implements get/set methods and a private member for a string XML attribute,
724 * plus a getXMLID override.
726 * @param proper the proper name of the attribute
728 #define IMPL_ID_ATTRIB(proper) \
729 IMPL_XMLOBJECT_ATTRIB(proper,XMLCh) \
730 const XMLCh* getXMLID() const { \
735 * Implements get/set methods and a private member for a string XML attribute,
736 * plus a getXMLID override and attribute node clearance when DOM is dropped.
738 * @param proper the proper name of the attribute
739 * @param ucase the upcased name of the attribute
740 * @param namespaceURI the XML namespace of the attribute
742 #define IMPL_ID_ATTRIB_EX(proper, ucase, namespaceURI) \
743 IMPL_XMLOBJECT_ATTRIB(proper,XMLCh) \
744 const XMLCh* getXMLID() const { \
747 void releaseDOM() const { \
749 getDOM()->removeAttributeNS(namespaceURI, ucase##_ATTRIB_NAME); \
750 AbstractDOMCachingXMLObject::releaseDOM(); \
754 * Implements get/set methods and a private member for a DateTime XML attribute.
756 * @param proper the proper name of the attribute
757 * @param fallback epoch to return when attribute is NULL
759 #define IMPL_DATETIME_ATTRIB(proper,fallback) \
760 IMPL_DATETIME_ATTRIB_EX(proper,fallback,false)
763 * Implements get/set methods and a private member for a duration-valued DateTime XML attribute.
765 * @param proper the proper name of the attribute
766 * @param fallback epoch to return when attribute is NULL
768 #define IMPL_DURATION_ATTRIB(proper,fallback) \
769 IMPL_DATETIME_ATTRIB_EX(proper,fallback,true)
772 * Implements get/set methods and a private member for a DateTime XML attribute.
774 * @param proper the proper name of the attribute
775 * @param fallback epoch to return when attribute is NULL
776 * @param duration true iff the attribute should be handled as a duration
778 #define IMPL_DATETIME_ATTRIB_EX(proper,fallback,duration) \
780 DateTime* m_##proper; \
781 time_t m_##proper##Epoch; \
783 const DateTime* get##proper() const { \
786 time_t get##proper##Epoch() const { \
787 return m_##proper ? m_##proper##Epoch : fallback; \
789 void set##proper(const DateTime* proper) { \
790 m_##proper = prepareForAssignment(m_##proper,proper); \
792 m_##proper##Epoch=m_##proper->getEpoch(duration); \
794 void set##proper(time_t proper) { \
795 m_##proper = prepareForAssignment(m_##proper,proper,duration); \
796 m_##proper##Epoch = proper; \
798 void set##proper(const XMLCh* proper) { \
799 m_##proper = prepareForAssignment(m_##proper,proper,duration); \
801 m_##proper##Epoch=m_##proper->getEpoch(duration); \
805 * Implements get/set methods and a private member for an integer XML attribute.
807 * @param proper the proper name of the attribute
809 #define IMPL_INTEGER_ATTRIB(proper) \
813 pair<bool,int> get##proper() const { \
816 return std::make_pair(true, xercesc::XMLString::parseInt(m_##proper)); \
819 return std::make_pair(true, 0); \
822 return std::make_pair(false, 0); \
825 void set##proper(const XMLCh* proper) { \
826 m_##proper = prepareForAssignment(m_##proper,proper); \
828 void set##proper(int proper) { \
830 std::string buf(boost::lexical_cast<std::string>(proper)); \
831 xmltooling::auto_ptr_XMLCh widen(buf.c_str()); \
832 set##proper(widen.get()); \
834 catch (boost::bad_lexical_cast&) { \
839 * Implements get/set methods and a private member for a boolean XML attribute.
841 * @param proper the proper name of the attribute
843 #define IMPL_BOOLEAN_ATTRIB(proper) \
845 xmlconstants::xmltooling_bool_t m_##proper; \
847 xmlconstants::xmltooling_bool_t get##proper() const { \
850 void proper(xmlconstants::xmltooling_bool_t value) { \
851 if (m_##proper != value) { \
852 releaseThisandParentDOM(); \
853 m_##proper = value; \
858 * Implements get/set methods and a private member for a typed, qualified XML attribute.
860 * @param proper the proper name of the attribute
861 * @param type the attribute's data type
863 #define IMPL_XMLOBJECT_FOREIGN_ATTRIB(proper,type) \
865 XMLCh* m_##proper##Prefix; \
868 const type* get##proper() const { \
871 void set##proper(const type* proper) { \
872 m_##proper = prepareForAssignment(m_##proper,proper); \
873 xercesc::XMLString::release(&m_##proper##Prefix); \
874 m_##proper##Prefix = nullptr; \
878 * Declares abstract set method for a typed XML child object in a foreign namespace.
879 * The get method is omitted.
881 * @param proper the proper name of the child type
882 * @param ns the C++ namespace for the type
884 #define DECL_INHERITED_TYPED_FOREIGN_CHILD(proper,ns) \
886 XMLTOOLING_DOXYGEN(Sets the proper child.) \
887 virtual void set##proper(ns::proper* child)=0
890 * Declares abstract get/set methods for a typed XML child object in a foreign namespace.
892 * @param proper the proper name of the child type
893 * @param ns the C++ namespace for the type
895 #define DECL_TYPED_FOREIGN_CHILD(proper,ns) \
897 XMLTOOLING_DOXYGEN(Returns the proper child.) \
898 virtual ns::proper* get##proper() const=0; \
899 XMLTOOLING_DOXYGEN(Sets the proper child.) \
900 virtual void set##proper(ns::proper* child)=0
903 * Declares abstract set method for a typed XML child object.
904 * The get method is omitted.
906 * @param proper the proper name of the child type
908 #define DECL_INHERITED_TYPED_CHILD(proper) \
910 XMLTOOLING_DOXYGEN(Sets the proper child.) \
911 virtual void set##proper(proper* child)=0
914 * Declares abstract get/set methods for a typed XML child object.
916 * @param proper the proper name of the child type
918 #define DECL_TYPED_CHILD(proper) \
920 XMLTOOLING_DOXYGEN(Returns the proper child.) \
921 virtual proper* get##proper() const=0; \
922 XMLTOOLING_DOXYGEN(Sets the proper child.) \
923 virtual void set##proper(proper* child)=0
926 * Declares abstract get/set methods for a generic XML child object.
928 * @param proper the proper name of the child
930 #define DECL_XMLOBJECT_CHILD(proper) \
932 XMLTOOLING_DOXYGEN(Returns the proper child.) \
933 virtual xmltooling::XMLObject* get##proper() const=0; \
934 XMLTOOLING_DOXYGEN(Sets the proper child.) \
935 virtual void set##proper(xmltooling::XMLObject* child)=0
939 * Implements get/set methods and a private list iterator member for a typed XML child object.
941 * @param proper the proper name of the child type
943 #define IMPL_TYPED_CHILD(proper) \
945 proper* m_##proper; \
946 std::list<xmltooling::XMLObject*>::iterator m_pos_##proper; \
948 proper* get##proper() const { \
951 void set##proper(proper* child) { \
952 prepareForAssignment(m_##proper,child); \
953 *m_pos_##proper = m_##proper = child; \
957 * Implements get/set methods and a private list iterator member for
958 * a typed XML child object in a foreign namespace
960 * @param proper the proper name of the child type
961 * @param ns the C++ namespace for the type
963 #define IMPL_TYPED_FOREIGN_CHILD(proper,ns) \
965 ns::proper* m_##proper; \
966 std::list<xmltooling::XMLObject*>::iterator m_pos_##proper; \
968 ns::proper* get##proper() const { \
971 void set##proper(ns::proper* child) { \
972 prepareForAssignment(m_##proper,child); \
973 *m_pos_##proper = m_##proper = child; \
977 * Implements get/set methods and a private list iterator member for a generic XML child object.
979 * @param proper the proper name of the child
981 #define IMPL_XMLOBJECT_CHILD(proper) \
983 xmltooling::XMLObject* m_##proper; \
984 std::list<xmltooling::XMLObject*>::iterator m_pos_##proper; \
986 xmltooling::XMLObject* get##proper() const { \
989 void set##proper(xmltooling::XMLObject* child) { \
990 prepareForAssignment(m_##proper,child); \
991 *m_pos_##proper = m_##proper = child; \
995 * Declares abstract get/set methods for a typed XML child collection.
997 * @param proper the proper name of the child type
999 #define DECL_TYPED_CHILDREN(proper) \
1001 XMLTOOLING_DOXYGEN(Returns modifiable proper collection.) \
1002 virtual VectorOf(proper) get##proper##s()=0; \
1003 XMLTOOLING_DOXYGEN(Returns reference to immutable proper collection.) \
1004 virtual const std::vector<proper*>& get##proper##s() const=0
1007 * Declares abstract get/set methods for a typed XML child collection in a foreign namespace.
1009 * @param proper the proper name of the child type
1010 * @param ns the C++ namespace for the type
1012 #define DECL_TYPED_FOREIGN_CHILDREN(proper,ns) \
1014 XMLTOOLING_DOXYGEN(Returns modifiable proper collection.) \
1015 virtual VectorOf(ns::proper) get##proper##s()=0; \
1016 XMLTOOLING_DOXYGEN(Returns reference to immutable proper collection.) \
1017 virtual const std::vector<ns::proper*>& get##proper##s() const=0
1020 * Declares abstract get/set methods for a generic XML child collection.
1022 * @param proper the proper name of the child
1024 #define DECL_XMLOBJECT_CHILDREN(proper) \
1026 XMLTOOLING_DOXYGEN(Returns modifiable proper collection.) \
1027 virtual VectorOf(xmltooling::XMLObject) get##proper##s()=0; \
1028 XMLTOOLING_DOXYGEN(Returns reference to immutable proper collection.) \
1029 virtual const std::vector<xmltooling::XMLObject*>& get##proper##s() const=0
1032 * Implements get method and a private vector member for a typed XML child collection.
1034 * @param proper the proper name of the child type
1035 * @param fence insertion fence for new objects of the child collection in backing list
1037 #define IMPL_TYPED_CHILDREN(proper,fence) \
1039 std::vector<proper*> m_##proper##s; \
1041 VectorOf(proper) get##proper##s() { \
1042 return VectorOf(proper)(this, m_##proper##s, &m_children, fence); \
1044 const std::vector<proper*>& get##proper##s() const { \
1045 return m_##proper##s; \
1049 * Implements get method and a private vector member for a typed XML child collection
1050 * in a foreign namespace.
1052 * @param proper the proper name of the child type
1053 * @param ns the C++ namespace for the type
1054 * @param fence insertion fence for new objects of the child collection in backing list
1056 #define IMPL_TYPED_FOREIGN_CHILDREN(proper,ns,fence) \
1058 std::vector<ns::proper*> m_##proper##s; \
1060 VectorOf(ns::proper) get##proper##s() { \
1061 return VectorOf(ns::proper)(this, m_##proper##s, &m_children, fence); \
1063 const std::vector<ns::proper*>& get##proper##s() const { \
1064 return m_##proper##s; \
1068 * Implements get method and a private vector member for a generic XML child collection.
1070 * @param proper the proper name of the child
1071 * @param fence insertion fence for new objects of the child collection in backing list
1073 #define IMPL_XMLOBJECT_CHILDREN(proper,fence) \
1075 std::vector<xmltooling::XMLObject*> m_##proper##s; \
1077 VectorOf(xmltooling::XMLObject) get##proper##s() { \
1078 return VectorOf(xmltooling::XMLObject)(this, m_##proper##s, &m_children, fence); \
1080 const std::vector<xmltooling::XMLObject*>& get##proper##s() const { \
1081 return m_##proper##s; \
1085 * Implements marshalling for a string attribute
1087 * @param proper the proper name of the attribute
1088 * @param ucase the upcased name of the attribute
1089 * @param namespaceURI the XML namespace of the attribute
1091 #define MARSHALL_STRING_ATTRIB(proper,ucase,namespaceURI) \
1092 if (m_##proper && *m_##proper) { \
1093 domElement->setAttributeNS(namespaceURI, ucase##_ATTRIB_NAME, m_##proper); \
1097 * Implements marshalling for a DateTime attribute
1099 * @param proper the proper name of the attribute
1100 * @param ucase the upcased name of the attribute
1101 * @param namespaceURI the XML namespace of the attribute
1103 #define MARSHALL_DATETIME_ATTRIB(proper,ucase,namespaceURI) \
1105 domElement->setAttributeNS(namespaceURI, ucase##_ATTRIB_NAME, m_##proper->getRawData()); \
1109 * Implements marshalling for an integer attribute
1111 * @param proper the proper name of the attribute
1112 * @param ucase the upcased name of the attribute
1113 * @param namespaceURI the XML namespace of the attribute
1115 #define MARSHALL_INTEGER_ATTRIB(proper,ucase,namespaceURI) \
1116 if (m_##proper && *m_##proper) { \
1117 domElement->setAttributeNS(namespaceURI, ucase##_ATTRIB_NAME, m_##proper); \
1121 * Implements marshalling for a boolean attribute
1123 * @param proper the proper name of the attribute
1124 * @param ucase the upcased name of the attribute
1125 * @param namespaceURI the XML namespace of the attribute
1127 #define MARSHALL_BOOLEAN_ATTRIB(proper,ucase,namespaceURI) \
1128 switch (m_##proper) { \
1129 case xmlconstants::XML_BOOL_TRUE: \
1130 domElement->setAttributeNS(namespaceURI, ucase##_ATTRIB_NAME, xmlconstants::XML_TRUE); \
1132 case xmlconstants::XML_BOOL_ONE: \
1133 domElement->setAttributeNS(namespaceURI, ucase##_ATTRIB_NAME, xmlconstants::XML_ONE); \
1135 case xmlconstants::XML_BOOL_FALSE: \
1136 domElement->setAttributeNS(namespaceURI, ucase##_ATTRIB_NAME, xmlconstants::XML_FALSE); \
1138 case xmlconstants::XML_BOOL_ZERO: \
1139 domElement->setAttributeNS(namespaceURI, ucase##_ATTRIB_NAME, xmlconstants::XML_ZERO); \
1141 case xmlconstants::XML_BOOL_NULL: \
1146 * Implements marshalling for a QName attribute
1148 * @param proper the proper name of the attribute
1149 * @param ucase the upcased name of the attribute
1150 * @param namespaceURI the XML namespace of the attribute
1152 #define MARSHALL_QNAME_ATTRIB(proper,ucase,namespaceURI) \
1154 xmltooling::auto_ptr_XMLCh qstr(m_##proper->toString().c_str()); \
1155 domElement->setAttributeNS(namespaceURI, ucase##_ATTRIB_NAME, qstr.get()); \
1158 #ifdef XMLTOOLING_XERCESC_BOOLSETIDATTRIBUTE
1160 * Implements marshalling for an ID attribute
1162 * @param proper the proper name of the attribute
1163 * @param ucase the upcased name of the attribute
1164 * @param namespaceURI the XML namespace of the attribute
1166 # define MARSHALL_ID_ATTRIB(proper,ucase,namespaceURI) \
1167 if (m_##proper && *m_##proper) { \
1168 domElement->setAttributeNS(namespaceURI, ucase##_ATTRIB_NAME, m_##proper); \
1169 domElement->setIdAttributeNS(namespaceURI, ucase##_ATTRIB_NAME, true); \
1173 * Implements marshalling for an ID attribute
1175 * @param proper the proper name of the attribute
1176 * @param ucase the upcased name of the attribute
1177 * @param namespaceURI the XML namespace of the attribute
1179 # define MARSHALL_ID_ATTRIB(proper,ucase,namespaceURI) \
1180 if (m_##proper && *m_##proper) { \
1181 domElement->setAttributeNS(namespaceURI, ucase##_ATTRIB_NAME, m_##proper); \
1182 domElement->setIdAttributeNS(namespaceURI, ucase##_ATTRIB_NAME); \
1187 * Implements unmarshalling process branch for a string attribute
1189 * @param proper the proper name of the attribute
1190 * @param ucase the upcased name of the attribute
1191 * @param namespaceURI the XML namespace of the attribute
1193 #define PROC_STRING_ATTRIB(proper,ucase,namespaceURI) \
1194 if (xmltooling::XMLHelper::isNodeNamed(attribute, namespaceURI, ucase##_ATTRIB_NAME)) { \
1195 set##proper(attribute->getValue()); \
1199 #ifdef XMLTOOLING_XERCESC_BOOLSETIDATTRIBUTE
1201 * Implements unmarshalling process branch for an ID attribute
1203 * @param proper the proper name of the attribute
1204 * @param ucase the upcased name of the attribute
1205 * @param namespaceURI the XML namespace of the attribute
1207 # define PROC_ID_ATTRIB(proper,ucase,namespaceURI) \
1208 if (xmltooling::XMLHelper::isNodeNamed(attribute, namespaceURI, ucase##_ATTRIB_NAME)) { \
1209 set##proper(attribute->getValue()); \
1210 attribute->getOwnerElement()->setIdAttributeNode(attribute, true); \
1215 * Implements unmarshalling process branch for an ID attribute
1217 * @param proper the proper name of the attribute
1218 * @param ucase the upcased name of the attribute
1219 * @param namespaceURI the XML namespace of the attribute
1221 # define PROC_ID_ATTRIB(proper,ucase,namespaceURI) \
1222 if (xmltooling::XMLHelper::isNodeNamed(attribute, namespaceURI, ucase##_ATTRIB_NAME)) { \
1223 set##proper(attribute->getValue()); \
1224 attribute->getOwnerElement()->setIdAttributeNode(attribute); \
1230 * Implements unmarshalling process branch for a DateTime attribute
1232 * @param proper the proper name of the attribute
1233 * @param ucase the upcased name of the attribute
1234 * @param namespaceURI the XML namespace of the attribute
1236 #define PROC_DATETIME_ATTRIB(proper,ucase,namespaceURI) \
1237 PROC_STRING_ATTRIB(proper,ucase,namespaceURI)
1240 * Implements unmarshalling process branch for a DateTime attribute
1242 * @param proper the proper name of the attribute
1243 * @param ucase the upcased name of the attribute
1244 * @param namespaceURI the XML namespace of the attribute
1246 #define PROC_QNAME_ATTRIB(proper,ucase,namespaceURI) \
1247 if (xmltooling::XMLHelper::isNodeNamed(attribute, namespaceURI, ucase##_ATTRIB_NAME)) { \
1248 std::auto_ptr<xmltooling::QName> q(xmltooling::XMLHelper::getAttributeValueAsQName(attribute)); \
1249 set##proper(q.get()); \
1254 * Implements unmarshalling process branch for an integer attribute
1256 * @param proper the proper name of the attribute
1257 * @param ucase the upcased name of the attribute
1258 * @param namespaceURI the XML namespace of the attribute
1260 #define PROC_INTEGER_ATTRIB(proper,ucase,namespaceURI) \
1261 PROC_STRING_ATTRIB(proper,ucase,namespaceURI)
1264 * Implements unmarshalling process branch for a boolean attribute
1266 * @param proper the proper name of the attribute
1267 * @param ucase the upcased name of the attribute
1268 * @param namespaceURI the XML namespace of the attribute
1270 #define PROC_BOOLEAN_ATTRIB(proper,ucase,namespaceURI) \
1271 PROC_STRING_ATTRIB(proper,ucase,namespaceURI)
1274 * Implements unmarshalling process branch for typed child collection element
1276 * @param proper the proper name of the child type
1277 * @param namespaceURI the XML namespace of the child element
1278 * @param force bypass use of hint and just cast down to check child
1280 #define PROC_TYPED_CHILDREN(proper,namespaceURI,force) \
1281 if (force || xmltooling::XMLHelper::isNodeNamed(root,namespaceURI,proper::LOCAL_NAME)) { \
1282 proper* typesafe=dynamic_cast<proper*>(childXMLObject); \
1284 get##proper##s().push_back(typesafe); \
1290 * Implements unmarshalling process branch for typed child collection element
1291 * in a foreign namespace.
1293 * @param proper the proper name of the child type
1294 * @param ns the C++ namespace for the type
1295 * @param namespaceURI the XML namespace of the child element
1296 * @param force bypass use of hint and just cast down to check child
1298 #define PROC_TYPED_FOREIGN_CHILDREN(proper,ns,namespaceURI,force) \
1299 if (force || xmltooling::XMLHelper::isNodeNamed(root,namespaceURI,ns::proper::LOCAL_NAME)) { \
1300 ns::proper* typesafe=dynamic_cast<ns::proper*>(childXMLObject); \
1302 get##proper##s().push_back(typesafe); \
1308 * Implements unmarshalling process branch for typed child singleton element
1310 * @param proper the proper name of the child type
1311 * @param namespaceURI the XML namespace of the child element
1312 * @param force bypass use of hint and just cast down to check child
1314 #define PROC_TYPED_CHILD(proper,namespaceURI,force) \
1315 if (force || xmltooling::XMLHelper::isNodeNamed(root,namespaceURI,proper::LOCAL_NAME)) { \
1316 proper* typesafe=dynamic_cast<proper*>(childXMLObject); \
1317 if (typesafe && !m_##proper) { \
1318 typesafe->setParent(this); \
1319 *m_pos_##proper = m_##proper = typesafe; \
1325 * Implements unmarshalling process branch for typed child singleton element
1326 * in a foreign namespace.
1328 * @param proper the proper name of the child type
1329 * @param ns the C++ namespace for the type
1330 * @param namespaceURI the XML namespace of the child element
1331 * @param force bypass use of hint and just cast down to check child
1333 #define PROC_TYPED_FOREIGN_CHILD(proper,ns,namespaceURI,force) \
1334 if (force || xmltooling::XMLHelper::isNodeNamed(root,namespaceURI,ns::proper::LOCAL_NAME)) { \
1335 ns::proper* typesafe=dynamic_cast<ns::proper*>(childXMLObject); \
1336 if (typesafe && !m_##proper) { \
1337 typesafe->setParent(this); \
1338 *m_pos_##proper = m_##proper = typesafe; \
1344 * Implements unmarshalling process branch for a generic child singleton element
1346 * @param proper the proper name of the child type
1347 * @param namespaceURI the XML namespace of the child element
1349 #define PROC_XMLOBJECT_CHILD(proper,namespaceURI) \
1350 if (xmltooling::XMLHelper::isNodeNamed(root,namespaceURI,proper::LOCAL_NAME)) { \
1351 if (!m_##proper) { \
1352 childXMLObject->setParent(this); \
1353 *m_pos_##proper = m_##proper = childXMLObject; \
1359 * Declares aliased get/set methods for named XML element simple content.
1361 * @param proper the proper name to label the element's content
1363 #define DECL_SIMPLE_CONTENT(proper) \
1364 XMLTOOLING_DOXYGEN(Returns proper.) \
1365 const XMLCh* get##proper() const { \
1366 return getTextContent(); \
1368 XMLTOOLING_DOXYGEN(Sets or clears proper.) \
1369 void set##proper(const XMLCh* proper) { \
1370 setTextContent(proper); \
1374 * Declares aliased get/set methods for named integer XML element content.
1376 * @param proper the proper name to label the element's content
1378 #define DECL_INTEGER_CONTENT(proper) \
1379 XMLTOOLING_DOXYGEN(Returns proper in integer form after a NULL indicator.) \
1380 std::pair<bool,int> get##proper() const { \
1381 if (getTextContent()) { \
1383 return std::make_pair(true, xercesc::XMLString::parseInt(getTextContent())); \
1386 return std::make_pair(true, 0); \
1389 return std::make_pair(false, 0); \
1392 XMLTOOLING_DOXYGEN(Sets proper.) \
1393 void set##proper(int proper) { \
1395 std::string buf(boost::lexical_cast<std::string>(proper)); \
1396 xmltooling::auto_ptr_XMLCh widen(buf.c_str()); \
1397 setTextContent(widen.get()); \
1399 catch (boost::bad_lexical_cast&) { \
1402 XMLTOOLING_DOXYGEN(Sets or clears proper.) \
1403 void set##proper(const XMLCh* proper) { \
1404 setTextContent(proper); \
1408 * Implements cloning methods for an XMLObject specialization implementation class.
1410 * @param cname the name of the XMLObject specialization
1412 #define IMPL_XMLOBJECT_CLONE(cname) \
1413 cname* clone##cname() const { \
1414 return dynamic_cast<cname*>(clone()); \
1416 xmltooling::XMLObject* clone() const { \
1417 std::auto_ptr<xmltooling::XMLObject> domClone(xmltooling::AbstractDOMCachingXMLObject::clone()); \
1418 cname##Impl* ret=dynamic_cast<cname##Impl*>(domClone.get()); \
1420 domClone.release(); \
1423 return new cname##Impl(*this); \
1427 * Implements cloning methods for an XMLObject specialization implementation class
1428 * that must override a base class clone method.
1430 * @param cname the name of the XMLObject specialization
1431 * @param base name of base type.
1433 #define IMPL_XMLOBJECT_CLONE2(cname,base) \
1434 cname* clone##cname() const { \
1435 return dynamic_cast<cname*>(clone()); \
1437 base* clone##base() const { \
1438 return dynamic_cast<base*>(clone()); \
1440 xmltooling::XMLObject* clone() const { \
1441 std::auto_ptr<xmltooling::XMLObject> domClone(xmltooling::AbstractDOMCachingXMLObject::clone()); \
1442 cname##Impl* ret=dynamic_cast<cname##Impl*>(domClone.get()); \
1444 domClone.release(); \
1447 return new cname##Impl(*this); \
1451 * Implements cloning methods for an XMLObject specialization implementation class that
1452 * needs two stage duplication to avoid invoking virtual methods during construction.
1454 * @param cname the name of the XMLObject specialization
1456 #define IMPL_XMLOBJECT_CLONE_EX(cname) \
1457 cname* clone##cname() const { \
1458 return dynamic_cast<cname*>(clone()); \
1460 xmltooling::XMLObject* clone() const { \
1461 std::auto_ptr<xmltooling::XMLObject> domClone(xmltooling::AbstractDOMCachingXMLObject::clone()); \
1462 cname##Impl* ret=dynamic_cast<cname##Impl*>(domClone.get()); \
1464 domClone.release(); \
1467 std::auto_ptr<cname##Impl> ret2(new cname##Impl(*this)); \
1468 ret2->_clone(*this); \
1469 return ret2.release(); \
1473 * Implements cloning methods for an XMLObject specialization implementation class that
1474 * needs two stage duplication to avoid invoking virtual methods during construction,
1475 * and must override a base class clone method.
1477 * @param cname the name of the XMLObject specialization
1478 * @param base name of base type
1480 #define IMPL_XMLOBJECT_CLONE_EX2(cname,base) \
1481 cname* clone##cname() const { \
1482 return dynamic_cast<cname*>(clone()); \
1484 base* clone##base() const { \
1485 return dynamic_cast<base*>(clone()); \
1487 xmltooling::XMLObject* clone() const { \
1488 std::auto_ptr<xmltooling::XMLObject> domClone(xmltooling::AbstractDOMCachingXMLObject::clone()); \
1489 cname##Impl* ret=dynamic_cast<cname##Impl*>(domClone.get()); \
1491 domClone.release(); \
1494 std::auto_ptr<cname##Impl> ret2(new cname##Impl(*this)); \
1495 ret2->_clone(*this); \
1496 return ret2.release(); \
1500 * Implements cloning of a child attribute, for use in copy constructor or
1501 * deferred clone methods.
1503 * proper the proper name of the attribute to clone
1505 #define IMPL_CLONE_ATTRIB(proper) \
1506 set##proper(src.get##proper())
1509 * Implements cloning of a child attribute in a foreign namespace, for use in copy constructor or
1510 * deferred clone methods.
1512 * proper the proper name of the attribute to clone
1514 #define IMPL_CLONE_FOREIGN_ATTRIB(proper) \
1515 set##proper(src.get##proper()); \
1516 if (src.m_##proper##Prefix) \
1517 m_##proper##Prefix = xercesc::XMLString::replicate(src.m_##proper##Prefix)
1520 * Implements cloning of an integer child attribute, for use in copy constructor or
1521 * deferred clone methods.
1523 * proper the proper name of the attribute to clone
1525 #define IMPL_CLONE_INTEGER_ATTRIB(proper) \
1526 set##proper(src.m_##proper)
1529 * Implements cloning of a boolean child attribute, for use in copy constructor or
1530 * deferred clone methods.
1532 * proper the proper name of the attribute to clone
1534 #define IMPL_CLONE_BOOLEAN_ATTRIB(proper) \
1535 proper(src.m_##proper)
1538 * Implements cloning of a child object, for use in copy constructor or
1539 * deferred clone methods.
1541 * proper the proper name of the child object to clone
1543 #define IMPL_CLONE_XMLOBJECT_CHILD(proper) \
1544 if (src.get##proper()) \
1545 set##proper(src.get##proper()->clone())
1548 * Implements cloning of a typed child object, for use in copy constructor or
1549 * deferred clone methods.
1551 * proper the proper name of the child type to clone
1553 #define IMPL_CLONE_TYPED_CHILD(proper) \
1554 if (src.get##proper()) \
1555 set##proper(src.get##proper()->clone##proper())
1558 * Implements cloning of an untyped child collection, for use in copy constructor or
1559 * deferred clone methods.
1561 * proper the proper name of the child type to clone
1563 #define IMPL_CLONE_XMLOBJECT_CHILDREN(proper) \
1564 static void (VectorOf(XMLObject)::* XMLObject_push_back)(XMLObject* const&) = &VectorOf(XMLObject)::push_back; \
1565 VectorOf(XMLObject) c##proper = get##proper##s(); \
1567 src.m_##proper##s.begin(), src.m_##proper##s.end(), \
1568 boost::lambda::if_(boost::lambda::_1 != ((XMLObject*)nullptr)) \
1569 [boost::lambda::bind(XMLObject_push_back, boost::ref(c##proper), boost::lambda::bind(&XMLObject::clone, boost::lambda::_1))] \
1573 * Implements cloning of a child collection, for use in copy constructor or
1574 * deferred clone methods.
1576 * proper the proper name of the child type to clone
1578 #define IMPL_CLONE_TYPED_CHILDREN(proper) \
1579 static void (VectorOf(proper)::* proper##_push_back)(proper* const&) = &VectorOf(proper)::push_back; \
1580 VectorOf(proper) c##proper = get##proper##s(); \
1582 src.m_##proper##s.begin(), src.m_##proper##s.end(), \
1583 boost::lambda::if_(boost::lambda::_1 != ((proper*)nullptr)) \
1584 [boost::lambda::bind(proper##_push_back, boost::ref(c##proper), boost::lambda::bind(&proper::clone##proper, boost::lambda::_1))] \
1588 * Implements cloning of a child collection in a foreign namespace, for use in copy constructor or
1589 * deferred clone methods.
1591 * proper the proper name of the child type to clone
1592 * ns the namespace of the child type
1594 #define IMPL_CLONE_TYPED_FOREIGN_CHILDREN(proper,ns) \
1595 static void (VectorOf(ns::proper)::* proper##_push_back)(ns::proper* const&) = &VectorOf(ns::proper)::push_back; \
1596 VectorOf(ns::proper) c##proper = get##proper##s(); \
1598 src.m_##proper##s.begin(), src.m_##proper##s.end(), \
1599 boost::lambda::if_(boost::lambda::_1 != ((ns::proper*)nullptr)) \
1600 [boost::lambda::bind(proper##_push_back, boost::ref(c##proper), boost::lambda::bind(&ns::proper::clone##proper, boost::lambda::_1))] \
1604 * Opens an iteration loop over all of the children of an object.
1606 #define IMPL_CLONE_CHILDBAG_BEGIN \
1607 for (list<xmltooling::XMLObject*>::const_iterator _bagit = src.m_children.begin(); _bagit != src.m_children.end(); ++_bagit) {
1610 * Closes an iteration loop over all of the children of an object.
1612 #define IMPL_CLONE_CHILDBAG_END }
1615 * Implements cloning of a typed child in a bag iteration loop based on a cast check.
1617 * @param proper the proper name of the child type to clone
1619 #define IMPL_CLONE_TYPED_CHILD_IN_BAG(proper) \
1620 proper* _##proper##cast = dynamic_cast<proper*>(*_bagit); \
1621 if (_##proper##cast) { \
1622 get##proper##s().push_back(_##proper##cast->clone##proper()); \
1627 * Implements cloning of a typed child in a forign namespace in a bag iteration loop based on a cast check.
1629 * @param proper the proper name of the child type to clone
1630 * @param ns the namespace of the child type
1632 #define IMPL_CLONE_TYPED_FOREIGN_CHILD_IN_BAG(proper,ns) \
1633 ns::proper* _##proper##cast = dynamic_cast<ns::proper*>(*_bagit); \
1634 if (_##proper##cast) { \
1635 get##proper##s().push_back(_##proper##cast->clone##proper()); \
1640 * Implements cloning of an XMLObject child in a bag iteration loop.
1642 * @param proper the proper name of the child to clone
1644 #define IMPL_CLONE_XMLOBJECT_CHILD_IN_BAG(proper) \
1646 get##proper##s().push_back((*_bagit)->clone()); \
1650 * Declares an XMLObject specialization with a simple content model and type,
1651 * handling it as string data.
1653 * @param linkage linkage specifier for the class
1654 * @param cname the name of the XMLObject specialization
1655 * @param proper the proper name to label the element's content
1656 * @param desc documentation for class
1658 #define DECL_XMLOBJECT_SIMPLE(linkage,cname,proper,desc) \
1659 BEGIN_XMLOBJECT(linkage,cname,xmltooling::XMLObject,desc); \
1660 DECL_SIMPLE_CONTENT(proper); \
1664 * Declares and defines an implementation class for an XMLObject with
1665 * a simple content model and type, handling it as string data.
1667 * @param linkage linkage specifier for the class
1668 * @param cname the name of the XMLObject specialization
1670 #define DECL_XMLOBJECTIMPL_SIMPLE(linkage,cname) \
1671 class linkage cname##Impl \
1672 : public virtual cname, \
1673 public xmltooling::AbstractSimpleElement, \
1674 public xmltooling::AbstractDOMCachingXMLObject, \
1675 public xmltooling::AbstractXMLObjectMarshaller, \
1676 public xmltooling::AbstractXMLObjectUnmarshaller \
1679 virtual ~cname##Impl() {} \
1680 cname##Impl(const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const xmltooling::QName* schemaType) \
1681 : xmltooling::AbstractXMLObject(nsURI, localName, prefix, schemaType) { \
1683 cname##Impl(const cname##Impl& src) \
1684 : xmltooling::AbstractXMLObject(src), \
1685 xmltooling::AbstractSimpleElement(src), \
1686 xmltooling::AbstractDOMCachingXMLObject(src) {} \
1687 IMPL_XMLOBJECT_CLONE(cname) \
1690 #ifdef HAVE_COVARIANT_RETURNS
1693 * Begins the declaration of an XMLObjectBuilder specialization.
1694 * Basic boilerplate includes an empty virtual destructor, and
1695 * a default builder that defaults the element name.
1697 * @param linkage linkage specifier for the class
1698 * @param cname the name of the XMLObject specialization
1699 * @param namespaceURI the XML namespace of the default associated element
1700 * @param namespacePrefix the XML namespace prefix of the default associated element
1702 #define BEGIN_XMLOBJECTBUILDER(linkage,cname,namespaceURI,namespacePrefix) \
1703 XMLTOOLING_DOXYGEN(Builder for cname objects.) \
1704 class linkage cname##Builder : public xmltooling::ConcreteXMLObjectBuilder { \
1706 virtual ~cname##Builder() {} \
1707 XMLTOOLING_DOXYGEN(Default builder.) \
1708 virtual cname* buildObject() const { \
1709 return buildObject(namespaceURI,cname::LOCAL_NAME,namespacePrefix); \
1711 XMLTOOLING_DOXYGEN(Builder that allows element/type override.) \
1712 virtual cname* buildObject( \
1713 const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix=nullptr, const xmltooling::QName* schemaType=nullptr \
1717 * Ends the declaration of an XMLObjectBuilder specialization.
1719 #define END_XMLOBJECTBUILDER }
1722 * Declares a generic XMLObjectBuilder specialization.
1724 * @param linkage linkage specifier for the class
1725 * @param cname the name of the XMLObject specialization
1726 * @param namespaceURI the XML namespace of the default associated element
1727 * @param namespacePrefix the XML namespace prefix of the default associated element
1729 #define DECL_XMLOBJECTBUILDER(linkage,cname,namespaceURI,namespacePrefix) \
1730 BEGIN_XMLOBJECTBUILDER(linkage,cname,namespaceURI,namespacePrefix); \
1731 XMLTOOLING_DOXYGEN(Singleton builder.) \
1732 static cname* build##cname() { \
1733 const cname##Builder* b = dynamic_cast<const cname##Builder*>( \
1734 XMLObjectBuilder::getBuilder(xmltooling::QName(namespaceURI,cname::LOCAL_NAME)) \
1737 return b->buildObject(); \
1738 throw xmltooling::XMLObjectException("Unable to obtain typed builder for "#cname"."); \
1740 END_XMLOBJECTBUILDER
1743 * Implements the standard XMLObjectBuilder specialization function.
1745 * @param cname the name of the XMLObject specialization
1747 #define IMPL_XMLOBJECTBUILDER(cname) \
1748 cname* cname##Builder::buildObject( \
1749 const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const xmltooling::QName* schemaType \
1752 return new cname##Impl(nsURI,localName,prefix,schemaType); \
1755 #else /* !HAVE_COVARIANT_RETURNS */
1758 * Begins the declaration of an XMLObjectBuilder specialization.
1759 * Basic boilerplate includes an empty virtual destructor, and
1760 * a default builder that defaults the element name.
1762 * @param linkage linkage specifier for the class
1763 * @param cname the name of the XMLObject specialization
1764 * @param namespaceURI the XML namespace of the default associated element
1765 * @param namespacePrefix the XML namespace prefix of the default associated element
1767 #define BEGIN_XMLOBJECTBUILDER(linkage,cname,namespaceURI,namespacePrefix) \
1768 XMLTOOLING_DOXYGEN(Builder for cname objects.) \
1769 class linkage cname##Builder : public xmltooling::ConcreteXMLObjectBuilder { \
1771 virtual ~cname##Builder() {} \
1772 XMLTOOLING_DOXYGEN(Default builder.) \
1773 virtual xmltooling::XMLObject* buildObject() const { \
1774 return buildObject(namespaceURI,cname::LOCAL_NAME,namespacePrefix); \
1776 XMLTOOLING_DOXYGEN(Builder that allows element/type override.) \
1777 virtual xmltooling::XMLObject* buildObject( \
1778 const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix=nullptr, const xmltooling::QName* schemaType=nullptr \
1782 * Ends the declaration of an XMLObjectBuilder specialization.
1784 #define END_XMLOBJECTBUILDER }
1787 * Declares a generic XMLObjectBuilder specialization.
1789 * @param linkage linkage specifier for the class
1790 * @param cname the name of the XMLObject specialization
1791 * @param namespaceURI the XML namespace of the default associated element
1792 * @param namespacePrefix the XML namespace prefix of the default associated element
1794 #define DECL_XMLOBJECTBUILDER(linkage,cname,namespaceURI,namespacePrefix) \
1795 BEGIN_XMLOBJECTBUILDER(linkage,cname,namespaceURI,namespacePrefix); \
1796 XMLTOOLING_DOXYGEN(Singleton builder.) \
1797 static cname* build##cname() { \
1798 const cname##Builder* b = dynamic_cast<const cname##Builder*>( \
1799 XMLObjectBuilder::getBuilder(xmltooling::QName(namespaceURI,cname::LOCAL_NAME)) \
1802 return dynamic_cast<cname*>(b->buildObject()); \
1803 throw xmltooling::XMLObjectException("Unable to obtain typed builder for "#cname"."); \
1805 END_XMLOBJECTBUILDER
1808 * Implements the standard XMLObjectBuilder specialization function.
1810 * @param cname the name of the XMLObject specialization
1812 #define IMPL_XMLOBJECTBUILDER(cname) \
1813 xmltooling::XMLObject* cname##Builder::buildObject( \
1814 const XMLCh* nsURI, const XMLCh* localName, const XMLCh* prefix, const xmltooling::QName* schemaType \
1817 return new cname##Impl(nsURI,localName,prefix,schemaType); \
1820 #endif /* HAVE_COVARIANT_RETURNS */
1823 * Begins the declaration of a Schema Validator specialization.
1825 * @param linkage linkage specifier for the class
1826 * @param cname the base name of the Validator specialization
1828 #define BEGIN_XMLOBJECTVALIDATOR(linkage,cname) \
1829 class linkage cname##SchemaValidator : public xmltooling::Validator \
1832 virtual ~cname##SchemaValidator() {} \
1833 virtual void validate(const xmltooling::XMLObject* xmlObject) const { \
1834 const cname* ptr=dynamic_cast<const cname*>(xmlObject); \
1836 throw xmltooling::ValidationException(#cname"SchemaValidator: unsupported object type ($1).",xmltooling::params(1,typeid(xmlObject).name())); \
1837 if (ptr->nil() && (ptr->hasChildren() || ptr->getTextContent())) \
1838 throw xmltooling::ValidationException("Object has nil property but with children or content.")
1841 * Begins the declaration of a Schema Validator specialization subclass.
1843 * @param linkage linkage specifier for the class
1844 * @param cname the base name of the Validator specialization
1845 * @param base base class for the validator
1847 #define BEGIN_XMLOBJECTVALIDATOR_SUB(linkage,cname,base) \
1848 class linkage cname##SchemaValidator : public base##SchemaValidator \
1851 virtual ~cname##SchemaValidator() {} \
1852 virtual void validate(const xmltooling::XMLObject* xmlObject) const { \
1853 const cname* ptr=dynamic_cast<const cname*>(xmlObject); \
1855 throw xmltooling::ValidationException(#cname"SchemaValidator: unsupported object type ($1).",xmltooling::params(1,typeid(xmlObject).name()));
1858 * Ends the declaration of a Validator specialization.
1860 #define END_XMLOBJECTVALIDATOR } }
1863 * Validator code that checks the object type.
1865 * @param cname the name of the XMLObject specialization
1867 #define XMLOBJECTVALIDATOR_CHECKTYPE(cname) \
1868 const cname* ptr=dynamic_cast<const cname*>(xmlObject); \
1870 throw xmltooling::ValidationException(#cname"SchemaValidator: unsupported object type ($1).",xmltooling::params(1,typeid(xmlObject).name()))
1873 * Validator code that checks for a required attribute, content, or singleton.
1875 * @param cname the name of the XMLObject specialization
1876 * @param proper the proper name of the attribute, content, or singleton member
1878 #define XMLOBJECTVALIDATOR_REQUIRE(cname,proper) \
1879 if (!ptr->get##proper()) \
1880 throw xmltooling::ValidationException(#cname" must have "#proper".")
1883 * Validator code that checks for a required integer attribute
1885 * @param cname the name of the XMLObject specialization
1886 * @param proper the proper name of the attribute, content, or singleton member
1888 #define XMLOBJECTVALIDATOR_REQUIRE_INTEGER(cname,proper) \
1889 if (!ptr->get##proper().first) \
1890 throw xmltooling::ValidationException(#cname" must have "#proper".")
1893 * Validator code that checks for one of a pair of
1894 * required attributes, content, or singletons.
1896 * @param cname the name of the XMLObject specialization
1897 * @param proper1 the proper name of the first attribute, content, or singleton member
1898 * @param proper2 the proper name of the second attribute, content, or singleton member
1900 #define XMLOBJECTVALIDATOR_ONEOF(cname,proper1,proper2) \
1901 if (!ptr->get##proper1() && !ptr->get##proper2()) \
1902 throw xmltooling::ValidationException(#cname" must have "#proper1" or "#proper2".")
1905 * Validator code that checks for one of a pair of
1906 * required attributes, content, or singletons, but disallows both.
1908 * @param cname the name of the XMLObject specialization
1909 * @param proper1 the proper name of the first attribute, content, or singleton member
1910 * @param proper2 the proper name of the second attribute, content, or singleton member
1912 #define XMLOBJECTVALIDATOR_ONLYONEOF(cname,proper1,proper2) \
1913 if ((!ptr->get##proper1() && !ptr->get##proper2()) || (ptr->get##proper1() && ptr->get##proper2())) \
1914 throw xmltooling::ValidationException(#cname" must have "#proper1" or "#proper2" but not both.")
1917 * Validator code that checks for one of a set of three
1918 * required attributes, content, or singletons.
1920 * @param cname the name of the XMLObject specialization
1921 * @param proper1 the proper name of the first attribute, content, or singleton member
1922 * @param proper2 the proper name of the second attribute, content, or singleton member
1923 * @param proper3 the proper name of the third attribute, content, or singleton member
1925 #define XMLOBJECTVALIDATOR_ONEOF3(cname,proper1,proper2,proper3) \
1926 if (!ptr->get##proper1() && !ptr->get##proper2() && !ptr->get##proper3()) \
1927 throw xmltooling::ValidationException(#cname" must have "#proper1", "#proper2", or "#proper3".")
1930 * Validator code that checks for one of a set of three
1931 * required attributes, content, or singletons but disallows more than one.
1933 * @param cname the name of the XMLObject specialization
1934 * @param proper1 the proper name of the first attribute, content, or singleton member
1935 * @param proper2 the proper name of the second attribute, content, or singleton member
1936 * @param proper3 the proper name of the third attribute, content, or singleton member
1938 #define XMLOBJECTVALIDATOR_ONLYONEOF3(cname,proper1,proper2,proper3) \
1939 int c##proper1##proper2##proper3=0; \
1940 if (ptr->get##proper1()!=nullptr) \
1941 c##proper1##proper2##proper3++; \
1942 if (ptr->get##proper2()!=nullptr) \
1943 c##proper1##proper2##proper3++; \
1944 if (ptr->get##proper3()!=nullptr) \
1945 c##proper1##proper2##proper3++; \
1946 if (c##proper1##proper2##proper3 != 1) \
1947 throw xmltooling::ValidationException(#cname" must have only one of "#proper1", "#proper2", or "#proper3".")
1950 * Validator code that checks a co-constraint (if one present, the other must be)
1951 * between a pair of attributes, content, or singletons.
1953 * @param cname the name of the XMLObject specialization
1954 * @param proper1 the proper name of the first attribute, content, or singleton member
1955 * @param proper2 the proper name of the second attribute, content, or singleton member
1957 #define XMLOBJECTVALIDATOR_NONEORBOTH(cname,proper1,proper2) \
1958 if ((ptr->get##proper1() && !ptr->get##proper2()) || (!ptr->get##proper1() && ptr->get##proper2())) \
1959 throw xmltooling::ValidationException(#cname" cannot have "#proper1" without "#proper2".")
1962 * Validator code that checks for a non-empty collection.
1964 * @param cname the name of the XMLObject specialization
1965 * @param proper the proper name of the collection item
1967 #define XMLOBJECTVALIDATOR_NONEMPTY(cname,proper) \
1968 if (ptr->get##proper##s().empty()) \
1969 throw xmltooling::ValidationException(#cname" must have at least one "#proper".")
1972 * Declares/defines a Validator specialization that checks object type and
1973 * a non-empty simple content model.
1975 * @param linkage linkage specifier for the class
1976 * @param cname the name of the XMLObject specialization
1978 #define XMLOBJECTVALIDATOR_SIMPLE(linkage,cname) \
1979 BEGIN_XMLOBJECTVALIDATOR(linkage,cname); \
1980 XMLOBJECTVALIDATOR_REQUIRE(cname,TextContent); \
1981 END_XMLOBJECTVALIDATOR
1986 * @namespace xmltooling
1987 * Public namespace of XML Tooling library
1989 namespace xmltooling {
1992 * Template function for cloning a sequence of XMLObjects.
1993 * Invokes the clone() member on each element of the input sequence and adds the copy to
1994 * the output sequence. Order is preserved.
1996 * @param in input sequence to clone
1997 * @param out output sequence to copy cloned pointers into
1999 template<class InputSequence,class OutputSequence> void clone(const InputSequence& in, OutputSequence& out) {
2000 for (typename InputSequence::const_iterator i=in.begin(); i!=in.end(); i++) {
2002 out.push_back((*i)->clone());
2009 * Functor for cleaning up heap objects in containers.
2011 template<class T> struct cleanup
2014 * Function operator to delete an object.
2016 * @param ptr object to delete
2018 void operator()(T* ptr) {delete ptr;}
2021 * Function operator to delete an object stored as const.
2023 * @param ptr object to delete after casting away const
2025 void operator()(const T* ptr) {delete const_cast<T*>(ptr);}
2029 * Functor for cleaning up heap objects in key/value containers.
2031 template<class A,class B> struct cleanup_pair
2034 * Function operator to delete an object.
2036 * @param p a pair in which the second component is the object to delete
2038 void operator()(const std::pair<const A,B*>& p) {delete p.second;}
2042 * Functor for cleaning up const heap objects in key/value containers.
2044 template<class A,class B> struct cleanup_const_pair
2047 * Function operator to delete an object stored as const
2049 * @param p a pair in which the second component is the const object to delete
2051 void operator()(const std::pair<const A,const B*>& p) {delete const_cast<B*>(p.second);}
2055 #endif /* __xmltooling_base_h__ */