KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > sun > enterprise > tools > common > dd > webservice > ServiceRefType


1 /**
2  * This generated bean class ServiceRefType matches the schema element service-refType
3  *
4  * ===============================================================
5  *
6  *
7  * This group keeps the usage of the contained description related
8  * elements consistent across J2EE deployment descriptors.
9  *
10  * All elements may occur multiple times with different languages,
11  * to support localization of the content.
12  *
13  *
14  * ===============================================================
15  * Generated on Fri Apr 22 15:42:58 PDT 2005
16  */

17
18 package com.sun.enterprise.tools.common.dd.webservice;
19
20 import org.w3c.dom.*;
21 import org.netbeans.modules.schema2beans.*;
22 import java.beans.*;
23 import java.util.*;
24
25 // BEGIN_NOI18N
26

27 public class ServiceRefType extends org.netbeans.modules.schema2beans.BaseBean
28 {
29
30     static Vector comparators = new Vector();
31
32     static public final String JavaDoc DESCRIPTION = "Description"; // NOI18N
33
static public final String JavaDoc DISPLAY_NAME = "DisplayName"; // NOI18N
34
static public final String JavaDoc ICON = "Icon"; // NOI18N
35
static public final String JavaDoc SERVICE_REF_NAME = "ServiceRefName"; // NOI18N
36
static public final String JavaDoc SERVICE_INTERFACE = "ServiceInterface"; // NOI18N
37
static public final String JavaDoc WSDL_FILE = "WsdlFile"; // NOI18N
38
static public final String JavaDoc JAXRPC_MAPPING_FILE = "JaxrpcMappingFile"; // NOI18N
39
static public final String JavaDoc SERVICE_QNAME = "ServiceQname"; // NOI18N
40
static public final String JavaDoc PORT_COMPONENT_REF = "PortComponentRef"; // NOI18N
41
static public final String JavaDoc HANDLER = "Handler"; // NOI18N
42

43     public ServiceRefType() {
44         this(Common.USE_DEFAULT_VALUES);
45     }
46
47     public ServiceRefType(int options)
48     {
49         super(comparators, new org.netbeans.modules.schema2beans.Version(1, 2, 0));
50         // Properties (see root bean comments for the bean graph)
51
this.createProperty("description", // NOI18N
52
DESCRIPTION,
53             Common.TYPE_0_N | Common.TYPE_STRING | Common.TYPE_KEY,
54             java.lang.String JavaDoc.class);
55         this.createAttribute(DESCRIPTION, "id", "Id",
56                         AttrProp.CDATA | AttrProp.IMPLIED,
57                         null, null);
58         this.createAttribute(DESCRIPTION, "xml:lang", "XmlLang",
59                         AttrProp.CDATA | AttrProp.IMPLIED,
60                         null, null);
61         this.createProperty("display-name", // NOI18N
62
DISPLAY_NAME,
63             Common.TYPE_0_N | Common.TYPE_STRING | Common.TYPE_KEY,
64             java.lang.String JavaDoc.class);
65         this.createAttribute(DISPLAY_NAME, "id", "Id",
66                         AttrProp.CDATA | AttrProp.IMPLIED,
67                         null, null);
68         this.createAttribute(DISPLAY_NAME, "xml:lang", "XmlLang",
69                         AttrProp.CDATA | AttrProp.IMPLIED,
70                         null, null);
71         this.createProperty("icon", // NOI18N
72
ICON,
73             Common.TYPE_0_N | Common.TYPE_BEAN | Common.TYPE_KEY,
74             IconType.class);
75         this.createAttribute(ICON, "xml:lang", "XmlLang",
76                         AttrProp.CDATA | AttrProp.IMPLIED,
77                         null, null);
78         this.createAttribute(ICON, "id", "Id",
79                         AttrProp.CDATA | AttrProp.IMPLIED,
80                         null, null);
81         this.createProperty("service-ref-name", // NOI18N
82
SERVICE_REF_NAME,
83             Common.TYPE_1 | Common.TYPE_STRING | Common.TYPE_KEY,
84             java.lang.String JavaDoc.class);
85         this.createProperty("service-interface", // NOI18N
86
SERVICE_INTERFACE,
87             Common.TYPE_1 | Common.TYPE_STRING | Common.TYPE_KEY,
88             java.lang.String JavaDoc.class);
89         this.createProperty("wsdl-file", // NOI18N
90
WSDL_FILE,
91             Common.TYPE_0_1 | Common.TYPE_STRING | Common.TYPE_KEY,
92             java.net.URI JavaDoc.class);
93         this.createAttribute(WSDL_FILE, "id", "Id",
94                         AttrProp.CDATA | AttrProp.IMPLIED,
95                         null, null);
96         this.createProperty("jaxrpc-mapping-file", // NOI18N
97
JAXRPC_MAPPING_FILE,
98             Common.TYPE_0_1 | Common.TYPE_STRING | Common.TYPE_KEY,
99             java.lang.String JavaDoc.class);
100         this.createProperty("service-qname", // NOI18N
101
SERVICE_QNAME,
102             Common.TYPE_0_1 | Common.TYPE_STRING | Common.TYPE_KEY,
103             javax.xml.namespace.QName JavaDoc.class);
104         this.createAttribute(SERVICE_QNAME, "id", "Id",
105                         AttrProp.CDATA | AttrProp.IMPLIED,
106                         null, null);
107         this.createProperty("port-component-ref", // NOI18N
108
PORT_COMPONENT_REF,
109             Common.TYPE_0_N | Common.TYPE_BEAN | Common.TYPE_KEY,
110             PortComponentRefType.class);
111         this.createAttribute(PORT_COMPONENT_REF, "id", "Id",
112                         AttrProp.CDATA | AttrProp.IMPLIED,
113                         null, null);
114         this.createProperty("handler", // NOI18N
115
HANDLER,
116             Common.TYPE_0_N | Common.TYPE_BEAN | Common.TYPE_KEY,
117             ServiceRefHandlerType.class);
118         this.createAttribute(HANDLER, "id", "Id",
119                         AttrProp.CDATA | AttrProp.IMPLIED,
120                         null, null);
121         this.initialize(options);
122     }
123
124     // Setting the default values of the properties
125
void initialize(int options)
126     {
127
128     }
129
130     // This attribute is an array, possibly empty
131
public void setDescription(int index, java.lang.String JavaDoc value) {
132         this.setValue(DESCRIPTION, index, value);
133     }
134
135     //
136
public java.lang.String JavaDoc getDescription(int index) {
137         return (java.lang.String JavaDoc)this.getValue(DESCRIPTION, index);
138     }
139
140     // This attribute is an array, possibly empty
141
public void setDescription(java.lang.String JavaDoc[] value) {
142         this.setValue(DESCRIPTION, value);
143     }
144
145     //
146
public java.lang.String JavaDoc[] getDescription() {
147         return (java.lang.String JavaDoc[])this.getValues(DESCRIPTION);
148     }
149
150     // Return the number of properties
151
public int sizeDescription() {
152         return this.size(DESCRIPTION);
153     }
154
155     // Add a new element returning its index in the list
156
public int addDescription(java.lang.String JavaDoc value) {
157         return this.addValue(DESCRIPTION, value);
158     }
159
160     //
161
// Remove an element using its reference
162
// Returns the index the element had in the list
163
//
164
public int removeDescription(java.lang.String JavaDoc value) {
165         return this.removeValue(DESCRIPTION, value);
166     }
167
168     // This attribute is an array, possibly empty
169
public void setDisplayName(int index, java.lang.String JavaDoc value) {
170         this.setValue(DISPLAY_NAME, index, value);
171     }
172
173     //
174
public java.lang.String JavaDoc getDisplayName(int index) {
175         return (java.lang.String JavaDoc)this.getValue(DISPLAY_NAME, index);
176     }
177
178     // This attribute is an array, possibly empty
179
public void setDisplayName(java.lang.String JavaDoc[] value) {
180         this.setValue(DISPLAY_NAME, value);
181     }
182
183     //
184
public java.lang.String JavaDoc[] getDisplayName() {
185         return (java.lang.String JavaDoc[])this.getValues(DISPLAY_NAME);
186     }
187
188     // Return the number of properties
189
public int sizeDisplayName() {
190         return this.size(DISPLAY_NAME);
191     }
192
193     // Add a new element returning its index in the list
194
public int addDisplayName(java.lang.String JavaDoc value) {
195         return this.addValue(DISPLAY_NAME, value);
196     }
197
198     //
199
// Remove an element using its reference
200
// Returns the index the element had in the list
201
//
202
public int removeDisplayName(java.lang.String JavaDoc value) {
203         return this.removeValue(DISPLAY_NAME, value);
204     }
205
206     // This attribute is an array, possibly empty
207
public void setIcon(int index, IconType value) {
208         this.setValue(ICON, index, value);
209     }
210
211     //
212
public IconType getIcon(int index) {
213         return (IconType)this.getValue(ICON, index);
214     }
215
216     // This attribute is an array, possibly empty
217
public void setIcon(IconType[] value) {
218         this.setValue(ICON, value);
219     }
220
221     //
222
public IconType[] getIcon() {
223         return (IconType[])this.getValues(ICON);
224     }
225
226     // Return the number of properties
227
public int sizeIcon() {
228         return this.size(ICON);
229     }
230
231     // Add a new element returning its index in the list
232
public int addIcon(com.sun.enterprise.tools.common.dd.webservice.IconType value) {
233         return this.addValue(ICON, value);
234     }
235
236     //
237
// Remove an element using its reference
238
// Returns the index the element had in the list
239
//
240
public int removeIcon(com.sun.enterprise.tools.common.dd.webservice.IconType value) {
241         return this.removeValue(ICON, value);
242     }
243
244     // This attribute is mandatory
245
public void setServiceRefName(java.lang.String JavaDoc value) {
246         this.setValue(SERVICE_REF_NAME, value);
247     }
248
249     //
250
public java.lang.String JavaDoc getServiceRefName() {
251         return (java.lang.String JavaDoc)this.getValue(SERVICE_REF_NAME);
252     }
253
254     // This attribute is mandatory
255
public void setServiceInterface(java.lang.String JavaDoc value) {
256         this.setValue(SERVICE_INTERFACE, value);
257     }
258
259     //
260
public java.lang.String JavaDoc getServiceInterface() {
261         return (java.lang.String JavaDoc)this.getValue(SERVICE_INTERFACE);
262     }
263
264     // This attribute is optional
265
public void setWsdlFile(java.net.URI JavaDoc value) {
266         this.setValue(WSDL_FILE, value);
267     }
268
269     //
270
public java.net.URI JavaDoc getWsdlFile() {
271         return (java.net.URI JavaDoc)this.getValue(WSDL_FILE);
272     }
273
274     // This attribute is optional
275
public void setJaxrpcMappingFile(java.lang.String JavaDoc value) {
276         this.setValue(JAXRPC_MAPPING_FILE, value);
277     }
278
279     //
280
public java.lang.String JavaDoc getJaxrpcMappingFile() {
281         return (java.lang.String JavaDoc)this.getValue(JAXRPC_MAPPING_FILE);
282     }
283
284     // This attribute is optional
285
public void setServiceQname(javax.xml.namespace.QName JavaDoc value) {
286         this.setValue(SERVICE_QNAME, value);
287     }
288
289     //
290
public javax.xml.namespace.QName JavaDoc getServiceQname() {
291         return (javax.xml.namespace.QName JavaDoc)this.getValue(SERVICE_QNAME);
292     }
293
294     // This attribute is an array, possibly empty
295
public void setPortComponentRef(int index, PortComponentRefType value) {
296         this.setValue(PORT_COMPONENT_REF, index, value);
297     }
298
299     //
300
public PortComponentRefType getPortComponentRef(int index) {
301         return (PortComponentRefType)this.getValue(PORT_COMPONENT_REF, index);
302     }
303
304     // This attribute is an array, possibly empty
305
public void setPortComponentRef(PortComponentRefType[] value) {
306         this.setValue(PORT_COMPONENT_REF, value);
307     }
308
309     //
310
public PortComponentRefType[] getPortComponentRef() {
311         return (PortComponentRefType[])this.getValues(PORT_COMPONENT_REF);
312     }
313
314     // Return the number of properties
315
public int sizePortComponentRef() {
316         return this.size(PORT_COMPONENT_REF);
317     }
318
319     // Add a new element returning its index in the list
320
public int addPortComponentRef(com.sun.enterprise.tools.common.dd.webservice.PortComponentRefType value) {
321         return this.addValue(PORT_COMPONENT_REF, value);
322     }
323
324     //
325
// Remove an element using its reference
326
// Returns the index the element had in the list
327
//
328
public int removePortComponentRef(com.sun.enterprise.tools.common.dd.webservice.PortComponentRefType value) {
329         return this.removeValue(PORT_COMPONENT_REF, value);
330     }
331
332     // This attribute is an array, possibly empty
333
public void setHandler(int index, ServiceRefHandlerType value) {
334         this.setValue(HANDLER, index, value);
335     }
336
337     //
338
public ServiceRefHandlerType getHandler(int index) {
339         return (ServiceRefHandlerType)this.getValue(HANDLER, index);
340     }
341
342     // This attribute is an array, possibly empty
343
public void setHandler(ServiceRefHandlerType[] value) {
344         this.setValue(HANDLER, value);
345     }
346
347     //
348
public ServiceRefHandlerType[] getHandler() {
349         return (ServiceRefHandlerType[])this.getValues(HANDLER);
350     }
351
352     // Return the number of properties
353
public int sizeHandler() {
354         return this.size(HANDLER);
355     }
356
357     // Add a new element returning its index in the list
358
public int addHandler(com.sun.enterprise.tools.common.dd.webservice.ServiceRefHandlerType value) {
359         return this.addValue(HANDLER, value);
360     }
361
362     //
363
// Remove an element using its reference
364
// Returns the index the element had in the list
365
//
366
public int removeHandler(com.sun.enterprise.tools.common.dd.webservice.ServiceRefHandlerType value) {
367         return this.removeValue(HANDLER, value);
368     }
369
370     //
371
public static void addComparator(org.netbeans.modules.schema2beans.BeanComparator c) {
372         comparators.add(c);
373     }
374
375     //
376
public static void removeComparator(org.netbeans.modules.schema2beans.BeanComparator c) {
377         comparators.remove(c);
378     }
379     public void validate() throws org.netbeans.modules.schema2beans.ValidateException {
380     }
381
382     // Dump the content of this bean returning it as a String
383
public void dump(StringBuffer JavaDoc str, String JavaDoc indent){
384         String JavaDoc s;
385         Object JavaDoc o;
386         org.netbeans.modules.schema2beans.BaseBean n;
387         str.append(indent);
388         str.append("Description["+this.sizeDescription()+"]"); // NOI18N
389
for(int i=0; i<this.sizeDescription(); i++)
390         {
391             str.append(indent+"\t");
392             str.append("#"+i+":");
393             str.append(indent+"\t"); // NOI18N
394
str.append("<"); // NOI18N
395
s = this.getDescription(i);
396             str.append((s==null?"null":s.trim())); // NOI18N
397
str.append(">\n"); // NOI18N
398
this.dumpAttributes(DESCRIPTION, i, str, indent);
399         }
400
401         str.append(indent);
402         str.append("DisplayName["+this.sizeDisplayName()+"]"); // NOI18N
403
for(int i=0; i<this.sizeDisplayName(); i++)
404         {
405             str.append(indent+"\t");
406             str.append("#"+i+":");
407             str.append(indent+"\t"); // NOI18N
408
str.append("<"); // NOI18N
409
s = this.getDisplayName(i);
410             str.append((s==null?"null":s.trim())); // NOI18N
411
str.append(">\n"); // NOI18N
412
this.dumpAttributes(DISPLAY_NAME, i, str, indent);
413         }
414
415         str.append(indent);
416         str.append("Icon["+this.sizeIcon()+"]"); // NOI18N
417
for(int i=0; i<this.sizeIcon(); i++)
418         {
419             str.append(indent+"\t");
420             str.append("#"+i+":");
421             n = (org.netbeans.modules.schema2beans.BaseBean) this.getIcon(i);
422             if (n != null)
423                 n.dump(str, indent + "\t"); // NOI18N
424
else
425                 str.append(indent+"\tnull"); // NOI18N
426
this.dumpAttributes(ICON, i, str, indent);
427         }
428
429         str.append(indent);
430         str.append("ServiceRefName"); // NOI18N
431
str.append(indent+"\t"); // NOI18N
432
str.append("<"); // NOI18N
433
s = this.getServiceRefName();
434         str.append((s==null?"null":s.trim())); // NOI18N
435
str.append(">\n"); // NOI18N
436
this.dumpAttributes(SERVICE_REF_NAME, 0, str, indent);
437
438         str.append(indent);
439         str.append("ServiceInterface"); // NOI18N
440
str.append(indent+"\t"); // NOI18N
441
str.append("<"); // NOI18N
442
s = this.getServiceInterface();
443         str.append((s==null?"null":s.trim())); // NOI18N
444
str.append(">\n"); // NOI18N
445
this.dumpAttributes(SERVICE_INTERFACE, 0, str, indent);
446
447         str.append(indent);
448         str.append("WsdlFile"); // NOI18N
449
str.append(indent+"\t"); // NOI18N
450
str.append("<"); // NOI18N
451
o = this.getWsdlFile();
452         str.append((o==null?"null":o.toString().trim())); // NOI18N
453
str.append(">\n"); // NOI18N
454
this.dumpAttributes(WSDL_FILE, 0, str, indent);
455
456         str.append(indent);
457         str.append("JaxrpcMappingFile"); // NOI18N
458
str.append(indent+"\t"); // NOI18N
459
str.append("<"); // NOI18N
460
s = this.getJaxrpcMappingFile();
461         str.append((s==null?"null":s.trim())); // NOI18N
462
str.append(">\n"); // NOI18N
463
this.dumpAttributes(JAXRPC_MAPPING_FILE, 0, str, indent);
464
465         str.append(indent);
466         str.append("ServiceQname"); // NOI18N
467
str.append(indent+"\t"); // NOI18N
468
str.append("<"); // NOI18N
469
o = this.getServiceQname();
470         str.append((o==null?"null":o.toString().trim())); // NOI18N
471
str.append(">\n"); // NOI18N
472
this.dumpAttributes(SERVICE_QNAME, 0, str, indent);
473
474         str.append(indent);
475         str.append("PortComponentRef["+this.sizePortComponentRef()+"]"); // NOI18N
476
for(int i=0; i<this.sizePortComponentRef(); i++)
477         {
478             str.append(indent+"\t");
479             str.append("#"+i+":");
480             n = (org.netbeans.modules.schema2beans.BaseBean) this.getPortComponentRef(i);
481             if (n != null)
482                 n.dump(str, indent + "\t"); // NOI18N
483
else
484                 str.append(indent+"\tnull"); // NOI18N
485
this.dumpAttributes(PORT_COMPONENT_REF, i, str, indent);
486         }
487
488         str.append(indent);
489         str.append("Handler["+this.sizeHandler()+"]"); // NOI18N
490
for(int i=0; i<this.sizeHandler(); i++)
491         {
492             str.append(indent+"\t");
493             str.append("#"+i+":");
494             n = (org.netbeans.modules.schema2beans.BaseBean) this.getHandler(i);
495             if (n != null)
496                 n.dump(str, indent + "\t"); // NOI18N
497
else
498                 str.append(indent+"\tnull"); // NOI18N
499
this.dumpAttributes(HANDLER, i, str, indent);
500         }
501
502     }
503     public String JavaDoc dumpBeanNode(){
504         StringBuffer JavaDoc str = new StringBuffer JavaDoc();
505         str.append("ServiceRefType\n"); // NOI18N
506
this.dump(str, "\n "); // NOI18N
507
return str.toString();
508     }}
509
510 // END_NOI18N
511

512
513 /*
514  * The contents of this file are subject to the terms
515  * of the Common Development and Distribution License
516  * (the License). You may not use this file except in
517  * compliance with the License.
518  *
519  * You can obtain a copy of the license at
520  * https://glassfish.dev.java.net/public/CDDLv1.0.html or
521  * glassfish/bootstrap/legal/CDDLv1.0.txt.
522  * See the License for the specific language governing
523  * permissions and limitations under the License.
524  *
525  * When distributing Covered Code, include this CDDL
526  * Header Notice in each file and include the License file
527  * at glassfish/bootstrap/legal/CDDLv1.0.txt.
528  * If applicable, add the following below the CDDL Header,
529  * with the fields enclosed by brackets [] replaced by
530  * you own identifying information:
531  * "Portions Copyrighted [year] [name of copyright owner]"
532  *
533  * Copyright 2006 Sun Microsystems, Inc. All rights reserved.
534  */

535
Popular Tags