1
2
3
4
5
6
7
8 package it.imolinfo.jbi4corba.webservice.generator;
9
10
11 import it.imolinfo.jbi4corba.webservice.generator.typedef.TypeDef;
12
13 import java.net.URLClassLoader;
14 import java.util.ArrayList;
15 import java.util.HashMap;
16 import java.util.HashSet;
17 import java.util.List;
18 import java.util.Map;
19 import java.util.Set;
20
21 import org.apache.commons.lang.builder.EqualsBuilder;
22 import org.apache.commons.lang.builder.ReflectionToStringBuilder;
23
24
25
26
27
28 public class ServerCorbaClassesHolder {
29
30 private Class webServiceInterface;
31 private Class webServiceImpl;
32 private Class corbaOperations;
33 private Class corbaPOATie;
34 private Class corbaHelper;
35 private boolean generateClassesFromIDL;
36
37
38
39
40 private Class corbaImplClass;
41
42 private URLClassLoader urlClassLoader;
43
44 private URLClassLoader originalClassLoader;
45
46
47
48
49
50 private Map<String, Object> valueTypeIdAndInstance;
51
52
53 private List<MethodSignature> methodSignatures
54 = new ArrayList<MethodSignature>();
55
56
57 private WsdlInformation wsdlInformation = null;
58
59
60 private Map<String, Map<String,String>> substitutedUnionFields
61 = new HashMap<String, Map<String,String>>();
62
63 private Map<String, UnionType> allUniontypes = null;
64
65
66 private Map<String, Map<String,String>> substitutedInterfaceFields
67 = new HashMap<String, Map<String,String>>();
68
69 private Map<String, InterfaceType> allInterfacetypes = null;
70
71
72 private Set<Class> allIDLTypes = new HashSet<Class>();
73
74
75 Map<String, List<String>> corbaEnumMap = new HashMap<String, List<String>>();
76
77 private Map<String,String> idTOClassNameMap = new HashMap<String, String>();
78
79 private Map<String, TypeDef> typeDefs = new HashMap<String, TypeDef>();
80
81
82
83
84 public WsdlInformation getWsdlInformation() {
85 return wsdlInformation;
86 }
87
88 public void setWsdlInformation(WsdlInformation wsdlInformation) {
89 this.wsdlInformation = wsdlInformation;
90 }
91
92
93
94
95 public ServerCorbaClassesHolder (){
96 }
97
98
99
100
101
102 public Map<String, Object> getValueTypeIdAndInstance() {
103 return valueTypeIdAndInstance;
104 }
105
106
107
108
109 public void setValueTypeIdAndInstance(Map<String, Object> valueTypeIdAndInstance) {
110 this.valueTypeIdAndInstance = valueTypeIdAndInstance;
111 }
112
113
114
115
116 public Class getCorbaOperations() {
117 return corbaOperations;
118 }
119
120
121
122
123 public void setCorbaOperations(Class corbaOperations) {
124 this.corbaOperations = corbaOperations;
125 }
126
127
128
129
130 public Class getCorbaPOATie() {
131 return corbaPOATie;
132 }
133
134
135
136
137 public void setCorbaPOATie(Class corbaPOATie) {
138 this.corbaPOATie = corbaPOATie;
139 }
140
141
142
143
144 public Class getWebServiceInterface() {
145 return webServiceInterface;
146 }
147
148
149
150
151 public void setWebServiceInterface(Class webServiceInterface) {
152 this.webServiceInterface = webServiceInterface;
153 }
154
155
156
157
158 public String toString() {
159 return ReflectionToStringBuilder.toString(this);
160 }
161
162
163
164
165
166 public boolean equals(Object obj) {
167 return EqualsBuilder.reflectionEquals(this, obj);
168 }
169
170
171
172
173 public Class getCorbaHelper() {
174 return corbaHelper;
175 }
176
177
178
179
180 public void setCorbaHelper(Class corbaHelper) {
181 this.corbaHelper = corbaHelper;
182 }
183
184
185
186
187 public URLClassLoader getUrlClassLoader() {
188 return urlClassLoader;
189 }
190
191
192
193
194 public void setUrlClassLoader(URLClassLoader urlClassLoader) {
195 this.urlClassLoader = urlClassLoader;
196 }
197
198 public Class getWebServiceImpl() {
199 return webServiceImpl;
200 }
201 public void setWebServiceImpl(Class webServiceImpl) {
202 this.webServiceImpl = webServiceImpl;
203 }
204
205
206
207
208
209
210 public Class getCorbaImplClass() {
211 return corbaImplClass;
212 }
213
214
215
216
217
218
219 public void setCorbaImplClass(Class corbaImpl) {
220 this.corbaImplClass = corbaImpl;
221 }
222
223 public boolean isGenerateClassesFromIDL() {
224 return generateClassesFromIDL;
225 }
226 public void setGenerateClassesFromIDL(boolean generateClassesFromIDL) {
227 this.generateClassesFromIDL = generateClassesFromIDL;
228 }
229
230
231
232
233
234
235 public URLClassLoader getOriginalClassLoader() {
236 return originalClassLoader;
237 }
238
239
240
241
242
243
244 public void setOriginalClassLoader(URLClassLoader originalClassLoader) {
245 this.originalClassLoader = originalClassLoader;
246 }
247
248
249 public List<MethodSignature> getMethodSignatures() {
250 return methodSignatures;
251 }
252
253 public void setMethodSignatures(List<MethodSignature> methodSignatures) {
254 this.methodSignatures = methodSignatures;
255 }
256
257 public Map<String, Map<String, String>> getSubstitutedUnionFields() {
258 return substitutedUnionFields;
259 }
260
261 public void setSubstitutedUnionFields(
262 Map<String, Map<String, String>> substitutedUnionFields) {
263 this.substitutedUnionFields = substitutedUnionFields;
264 }
265
266 public Map<String, UnionType> getAllUniontypes() {
267 return allUniontypes;
268 }
269
270 public void setAllUniontypes(Map<String, UnionType> allUniontypes) {
271 this.allUniontypes = allUniontypes;
272 }
273
274 public void setSubstitutedInterfaceFields(
275 Map<String, Map<String, String>> substitutedInterfaceFields) {
276 this.substitutedInterfaceFields = substitutedInterfaceFields;
277 }
278
279 public Map<String, InterfaceType> getAllInterfacetypes() {
280 return allInterfacetypes;
281 }
282
283 public void setAllInterfacetypes(Map<String, InterfaceType> allInterfaceypes) {
284 this.allInterfacetypes = allInterfaceypes;
285 }
286
287 public Map<String, SearchedType> getAllCorbaTypes() {
288 Map<String, SearchedType> allCorbaTypes = new HashMap<String, SearchedType>();
289
290 allCorbaTypes.putAll(allInterfacetypes);
291 allCorbaTypes.putAll(allUniontypes);
292
293 return allCorbaTypes;
294 }
295
296 public Set<Class> getAllIDLTypes() {
297 return allIDLTypes;
298 }
299
300 public void setAllIDLTypes(Set<Class> allIDLTypes) {
301 this.allIDLTypes = allIDLTypes;
302 }
303
304 public Map<String, List<String>> getCorbaEnumMap() {
305 return corbaEnumMap;
306 }
307
308 public void setCorbaEnumMap(Map<String, List<String>> corbaEnumMap) {
309 this.corbaEnumMap = corbaEnumMap;
310 }
311
312 public void setIdToClassNameMap(Map<String, String> idToClassMap) {
313 idTOClassNameMap=idToClassMap;
314 }
315
316 public Map<String,String> getIdToClassNameMap(){
317 return idTOClassNameMap;
318 }
319
320 public Map<String, TypeDef> getTypeDefs() {
321 return typeDefs;
322 }
323
324 public void setTypeDefs(Map<String, TypeDef> typeDefs) {
325 this.typeDefs = typeDefs;
326 }
327
328
329 }