2 * CDE - Common Desktop Environment
4 * Copyright (c) 1993-2012, The Open Group. All rights reserved.
6 * These libraries and programs are free software; you can
7 * redistribute them and/or modify them under the terms of the GNU
8 * Lesser General Public License as published by the Free Software
9 * Foundation; either version 2 of the License, or (at your option)
12 * These libraries and programs are distributed in the hope that
13 * they will be useful, but WITHOUT ANY WARRANTY; without even the
14 * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
15 * PURPOSE. See the GNU Lesser General Public License for more
18 * You should have received a copy of the GNU Lesser General Public
19 * License along with these librararies and programs; if not, write
20 * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
21 * Floor, Boston, MA 02110-1301 USA
23 // $XConsortium: SSTemplates.C /main/8 1996/10/09 15:29:50 rcs $
26 * (c) Copyright 1996 Digital Equipment Corporation.
27 * (c) Copyright 1996 Hewlett-Packard Company.
28 * (c) Copyright 1996 International Business Machines Corp.
29 * (c) Copyright 1996 Sun Microsystems, Inc.
30 * (c) Copyright 1996 Novell, Inc.
31 * (c) Copyright 1996 FUJITSU LIMITED.
32 * (c) Copyright 1996 Hitachi.
35 //#include "StyleSheet/cde_next.h"
38 #include "Attribute.h"
39 #include "FeatureValue.h"
40 #include "AttributeList.h"
43 #include "BitVector.h"
44 #include "PathTable.h"
46 #include "Expression.h"
49 #include "ResolverStack.h"
50 #include "FeatureDefDictionary.h"
53 #include "dti_cc/cc_hdict.h"
54 #include "dti_cc/CC_Slist.h"
55 #include "dti_cc/CC_Dlist.h"
56 #include "dti_cc/cc_povec.h"
57 #include "dti_cc/cc_vvect.h"
58 #include "dti_cc/cc_pvect.h"
62 /* for features test program - jbm */
64 typedef Stack<FeatureSet*,dlist_array<FeatureSet> > _stack_fs_orvec_fs_;
68 // Update this field whenever an ID is assigned. - qifan
69 // the largest ID used in f's: 59
72 #if defined(sun) || defined(hpux) || defined (__uxp__) || defined (USL)
73 typedef CC_TPtrSlist<Attribute> _f4_;
74 typedef CC_TPtrSlist<Feature> _f5_;
75 typedef CC_TPtrSlist<PathFeature> _f2_;
76 typedef CC_TPtrSlist<FeatureValue> _f55_;
77 typedef CC_TPtrSlist<FeatureDef> _f56_;
78 typedef CC_TPtrSlist<TypeValues> _f57_;
79 typedef CC_TPtrSlist<char> _f44_;
81 typedef CC_TPtrDlist<PathFeature> _f1_;
82 typedef CC_TPtrDlist<Symbol> _f6_;
83 typedef CC_TPtrDlist<ResolverStackElement> _f7_;
84 typedef CC_TPtrDlist<char> _f50_;
86 typedef hashTable<SymbolName, unsigned int> _f3_;
87 typedef hashTable<Symbol, Expression> _f8_;
88 typedef hashTable<unsigned int,BitVector> _f9_;
90 typedef hashTableIterator<SymbolName,unsigned int> _f13_;
91 typedef hashTableIterator<unsigned int,BitVector> _f21_;
92 typedef hashTableIterator<Symbol, Expression> _hash_dict_iter_sym_exp_;
93 typedef hashTableIterator<FeatureDef, FeatureDef> _f59_;
96 typedef CC_TPtrSlistDictionary<SymbolName,unsigned int> _f31_;
97 typedef CC_TPtrSlistDictionary<unsigned int,BitVector> _f32_;
98 typedef CC_TPtrSlistDictionary<Symbol,Expression> _f33_;
99 typedef CC_TPtrSlistDictionary<SymbolName,unsigned int> _f34_;
102 typedef dlist_array<CC_String> _ordvec_cstring_ ;
103 typedef CC_TValSlist<posRecord> _f54_;
104 typedef value_vector<PathTermPtr> _PathTermPtrvalue_vector_;
105 typedef pointer_vector<FeatureValue> _pointer_vector_FeatureValue_;
111 #pragma define( CC_TPtrSlist<Attribute> )
112 #pragma define( CC_TPtrSlist<Feature> )
113 #pragma define( CC_TPtrSlist<PathFeature> )
114 #pragma define( CC_TPtrSlist<FeatureValue> )
115 #pragma define( CC_TPtrSlist<FeatureDef> )
116 #pragma define( CC_TPtrSlist<TypeValues> )
117 #pragma define( CC_TPtrSlist<char> )
119 #pragma define( CC_TPtrDlist<PathFeature> )
120 #pragma define( CC_TPtrDlist<Symbol> )
121 #pragma define( CC_TPtrDlist<ResolverStackElement> )
122 #pragma define( CC_TPtrDlist<char> )
124 #pragma define( hashTable<Symbol, Expression> )
125 #pragma define( hashTable<SymbolName, unsigned int> )
126 #pragma define( hashTable<unsigned int,BitVector> )
128 #pragma define( hashTableIterator<SymbolName,unsigned int> )
129 #pragma define( hashTableIterator<unsigned int,BitVector> )
130 #pragma define( hashTableIterator<Symbol, Expression> )
131 #pragma define( hashTableIterator<FeatureDef, FeatureDef> )
135 #pragma define( CC_TPtrSlistDictionary<SymbolName,unsigned int> )
136 #pragma define( CC_TPtrSlistDictionary<unsigned int,BitVector> )
137 #pragma define( CC_TPtrSlistDictionary<Symbol,Expression> )
138 #pragma define( CC_TPtrSlistDictionary<SymbolName,unsigned int> )
141 typedef dlist_array<CC_String> _ordvec_cstring_ ;
142 typedef CC_TValSlist<posRecord> _f54_;
143 typedef value_vector<PathTermPtr> _PathTermPtrvalue_vector_;
144 typedef pointer_vector<FeatureValue> _pointer_vector_FeatureValue_;
146 #pragma define( dlist_array<CC_String> )
147 #pragma define( CC_TValSlist<posRecord> )
148 #pragma define( value_vector<PathTermPtr> )
149 #pragma define( pointer_vector<FeatureValue> )
154 // The following are initializations for a static member
155 // function that the DEC compiler wouldn't let me initialize
156 // in the template definition
159 CC_Boolean kv_pair<SymbolName, unsigned int>::f_needRemove = FALSE;
160 CC_Boolean kv_pair<unsigned int, BitVector>::f_needRemove = FALSE;
161 CC_Boolean kv_pair<Symbol, Expression>::f_needRemove = FALSE;
162 CC_Boolean kv_pair<FeatureDef, FeatureDef>::f_needRemove = FALSE;
164 #pragma define_template CC_TPtrSlist<CC_String>
165 #pragma define_template CC_TPtrDlist<CC_String>
167 #pragma define_template CC_TPtrSlist<Attribute>
168 #pragma define_template CC_TPtrSlist<Feature>
169 #pragma define_template CC_TPtrSlist<PathFeature>
170 #pragma define_template CC_TPtrSlist<FeatureValue>
171 #pragma define_template CC_TPtrSlist<FeatureDef>
172 #pragma define_template CC_TPtrSlist<TypeValues>
173 #pragma define_template CC_TPtrSlist<char>
175 #pragma define_template CC_TPtrDlist<PathFeature>
176 #pragma define_template CC_TPtrDlist<Symbol>
177 #pragma define_template CC_TPtrDlist<ResolverStackElement>
178 #pragma define_template CC_TPtrDlist<char>
180 #pragma define_template hashTable<SymbolName, unsigned int>
181 #pragma define_template hashTable<Symbol, Expression>
182 #pragma define_template hashTable<unsigned int,BitVector>
184 #pragma define_template hashTableIterator<SymbolName,unsigned int>
185 #pragma define_template hashTableIterator<unsigned int,BitVector>
186 #pragma define_template hashTableIterator<Symbol, Expression>
187 #pragma define_template hashTableIterator<FeatureDef, FeatureDef>
191 #pragma define_template CC_TPtrSlistDictionary<SymbolName,unsigned int>
192 #pragma define_template CC_TPtrSlistDictionary<unsigned int,BitVector>
193 #pragma define_template CC_TPtrSlistDictionary<Symbol,Expression>
194 #pragma define_template CC_TPtrSlistDictionary<SymbolName,unsigned int>
197 typedef dlist_array<CC_String> _ordvec_cstring_ ;
198 typedef CC_TValSlist<posRecord> _f54_;
199 typedef value_vector<PathTermPtr> _PathTermPtrvalue_vector_;
200 typedef pointer_vector<FeatureValue> _pointer_vector_FeatureValue_;
202 #pragma define_template dlist_array<CC_String>
203 #pragma define_template CC_TValSlist<posRecord>
204 #pragma define_template value_vector<PathTermPtr>
205 #pragma define_template pointer_vector<FeatureValue>
207 // unresolved references
209 #pragma define_template CC_TPtrDlist<PathTerm>
210 #pragma define_template CC_TPtrDlistIterator<PathTerm>
211 #pragma define_template CC_TValSlistIterator<posRecord>
212 #pragma define_template CC_TPtrSlist<Symbol>
213 #pragma define_template dlist_array<Symbol>
214 #pragma define_template CC_TPtrSlist<ResolverStackElement>
215 #pragma define_template kv_pair<SymbolName, unsigned int>
216 #pragma define_template CC_TPtrSlist<kv_pair<SymbolName, unsigned int> >
217 #pragma define_template pointer_vector<CC_TPtrSlist<kv_pair<SymbolName, unsigned int> > >
218 #pragma define_template CC_TPtrSlist<kv_pair<unsigned int, BitVector> >
219 #pragma define_template pointer_vector<CC_TPtrSlist<kv_pair<unsigned int, BitVector> > >
220 #pragma define_template CC_TPtrSlist<Symbol>
221 #pragma define_template kv_pair<Symbol, Expression>
222 #pragma define_template CC_TPtrSlist<kv_pair<Symbol, Expression> >
223 #pragma define_template pointer_vector<CC_TPtrSlist<kv_pair<Symbol, Expression> > >
224 #pragma define_template CC_TPtrSlist<kv_pair<FeatureDef, FeatureDef> >
225 #pragma define_template pointer_vector<CC_TPtrSlist<kv_pair<FeatureDef, FeatureDef> > >
226 #pragma define_template CC_TValSlist<int>
227 #pragma define_template CC_TValSlistIterator<int>
228 #pragma define_template CC_TValSlistIterator<char>
229 // #pragma define_template CC_TValSlistIterator<char*>
230 // #pragma define_template C_TValSlistIterator<TableDefn*>
231 #pragma define_template kv_pair<unsigned int, BitVector>
232 #pragma define_template kv_pair<FeatureDef, FeatureDef>
233 #pragma define_template CC_TPtrSlist<PathTerm>
238 #pragma instantiate CC_TPtrSlist<CC_String>
239 #pragma instantiate CC_TPtrDlist<CC_String>
241 #pragma instantiate CC_TPtrSlist<Attribute>
242 #pragma instantiate CC_TPtrSlist<Feature>
243 #pragma instantiate CC_TPtrSlist<PathFeature>
244 #pragma instantiate CC_TPtrSlist<FeatureValue>
245 #pragma instantiate CC_TPtrSlist<FeatureDef>
246 #pragma instantiate CC_TPtrSlist<TypeValues>
247 #pragma instantiate CC_TPtrSlist<char>
249 #pragma instantiate CC_TPtrDlist<PathFeature>
250 #pragma instantiate CC_TPtrDlist<Symbol>
251 #pragma instantiate CC_TPtrDlist<ResolverStackElement>
252 #pragma instantiate CC_TPtrDlist<char>
254 #pragma instantiate hashTable<SymbolName, unsigned int>
255 #pragma instantiate hashTable<Symbol, Expression>
256 #pragma instantiate hashTable<unsigned int,BitVector>
258 #pragma instantiate hashTableIterator<SymbolName,unsigned int>
259 #pragma instantiate hashTableIterator<unsigned int,BitVector>
260 #pragma instantiate hashTableIterator<Symbol, Expression>
261 #pragma instantiate hashTableIterator<FeatureDef, FeatureDef>
265 #pragma instantiate CC_TPtrSlistDictionary<SymbolName,unsigned int>
266 #pragma instantiate CC_TPtrSlistDictionary<unsigned int,BitVector>
267 #pragma instantiate CC_TPtrSlistDictionary<Symbol,Expression>
268 #pragma instantiate CC_TPtrSlistDictionary<SymbolName,unsigned int>
271 typedef dlist_array<CC_String> _ordvec_cstring_ ;
272 typedef CC_TValSlist<posRecord> _f54_;
273 typedef value_vector<PathTermPtr> _PathTermPtrvalue_vector_;
274 typedef pointer_vector<FeatureValue> _pointer_vector_FeatureValue_;
276 #pragma instantiate dlist_array<CC_String>
277 #pragma instantiate CC_TValSlist<posRecord>
278 #pragma instantiate value_vector<PathTermPtr>
279 #pragma instantiate pointer_vector<FeatureValue>
281 // unresolved references
283 #pragma instantiate CC_TPtrDlist<PathTerm>
284 #pragma instantiate CC_TPtrDlistIterator<PathTerm>
285 #pragma instantiate CC_TValSlistIterator<posRecord>
286 #pragma instantiate CC_TPtrSlist<Symbol>
287 #pragma instantiate dlist_array<Symbol>
288 #pragma instantiate CC_TPtrSlist<ResolverStackElement>
289 #pragma instantiate kv_pair<SymbolName, unsigned int>
290 #pragma instantiate CC_TPtrSlist<kv_pair<SymbolName, unsigned int> >
291 #pragma instantiate pointer_vector<CC_TPtrSlist<kv_pair<SymbolName, unsigned int> > >
292 #pragma instantiate CC_TPtrSlist<kv_pair<unsigned int, BitVector> >
293 #pragma instantiate pointer_vector<CC_TPtrSlist<kv_pair<unsigned int, BitVector> > >
294 #pragma instantiate CC_TPtrSlist<Symbol>
295 #pragma instantiate kv_pair<Symbol, Expression>
296 #pragma instantiate CC_TPtrSlist<kv_pair<Symbol, Expression> >
297 #pragma instantiate pointer_vector<CC_TPtrSlist<kv_pair<Symbol, Expression> > >
298 #pragma instantiate CC_TPtrSlist<kv_pair<FeatureDef, FeatureDef> >
299 #pragma instantiate pointer_vector<CC_TPtrSlist<kv_pair<FeatureDef, FeatureDef> > >
300 #pragma instantiate CC_TValSlist<int>
301 #pragma instantiate CC_TValSlistIterator<int>
302 #pragma instantiate CC_TValSlistIterator<char>
304 #pragma instantiate kv_pair<unsigned int, BitVector>
305 #pragma instantiate kv_pair<FeatureDef, FeatureDef>
306 #pragma instantiate CC_TPtrSlist<PathTerm>