KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > sun > enterprise > tools > common > dd > ejb > Ejb


1 /**
2  * This generated bean class Ejb matches the schema element ejb
3  *
4  * Generated on Wed Mar 03 14:29:49 PST 2004
5  */

6
7 package com.sun.enterprise.tools.common.dd.ejb;
8
9 import org.w3c.dom.*;
10 import org.netbeans.modules.schema2beans.*;
11 import java.beans.*;
12 import java.util.*;
13 import com.sun.enterprise.tools.common.dd.ResourceRef;
14 import com.sun.enterprise.tools.common.dd.EjbRef;
15 import com.sun.enterprise.tools.common.dd.ResourceEnvRef;
16 import com.sun.enterprise.tools.common.dd.ServiceRef;
17 import com.sun.enterprise.tools.common.dd.WebserviceEndpoint;
18
19 // BEGIN_NOI18N
20

21 public class Ejb extends com.sun.enterprise.tools.common.dd.SunBaseBean
22 {
23
24     static Vector comparators = new Vector();
25
26     static public final String JavaDoc AVAILABILITYENABLED = "AvailabilityEnabled"; // NOI18N
27
static public final String JavaDoc EJB_NAME = "EjbName"; // NOI18N
28
static public final String JavaDoc JNDI_NAME = "JndiName"; // NOI18N
29
static public final String JavaDoc EJB_REF = "EjbRef"; // NOI18N
30
static public final String JavaDoc RESOURCE_REF = "ResourceRef"; // NOI18N
31
static public final String JavaDoc RESOURCE_ENV_REF = "ResourceEnvRef"; // NOI18N
32
static public final String JavaDoc SERVICE_REF = "ServiceRef"; // NOI18N
33
static public final String JavaDoc PASS_BY_REFERENCE = "PassByReference"; // NOI18N
34
static public final String JavaDoc CMP = "Cmp"; // NOI18N
35
static public final String JavaDoc PRINCIPAL = "Principal"; // NOI18N
36
static public final String JavaDoc MDB_CONNECTION_FACTORY = "MdbConnectionFactory"; // NOI18N
37
static public final String JavaDoc JMS_DURABLE_SUBSCRIPTION_NAME = "JmsDurableSubscriptionName"; // NOI18N
38
static public final String JavaDoc JMS_MAX_MESSAGES_LOAD = "JmsMaxMessagesLoad"; // NOI18N
39
static public final String JavaDoc IOR_SECURITY_CONFIG = "IorSecurityConfig"; // NOI18N
40
static public final String JavaDoc IS_READ_ONLY_BEAN = "IsReadOnlyBean"; // NOI18N
41
static public final String JavaDoc REFRESH_PERIOD_IN_SECONDS = "RefreshPeriodInSeconds"; // NOI18N
42
static public final String JavaDoc COMMIT_OPTION = "CommitOption"; // NOI18N
43
static public final String JavaDoc CMT_TIMEOUT_IN_SECONDS = "CmtTimeoutInSeconds"; // NOI18N
44
static public final String JavaDoc USE_THREAD_POOL_ID = "UseThreadPoolId"; // NOI18N
45
static public final String JavaDoc GEN_CLASSES = "GenClasses"; // NOI18N
46
static public final String JavaDoc BEAN_POOL = "BeanPool"; // NOI18N
47
static public final String JavaDoc BEAN_CACHE = "BeanCache"; // NOI18N
48
static public final String JavaDoc MDB_RESOURCE_ADAPTER = "MdbResourceAdapter"; // NOI18N
49
static public final String JavaDoc WEBSERVICE_ENDPOINT = "WebserviceEndpoint"; // NOI18N
50
static public final String JavaDoc FLUSH_AT_END_OF_METHOD = "FlushAtEndOfMethod"; // NOI18N
51
static public final String JavaDoc CHECKPOINTED_METHODS = "CheckpointedMethods"; // NOI18N
52
static public final String JavaDoc CHECKPOINT_AT_END_OF_METHOD = "CheckpointAtEndOfMethod"; // NOI18N
53

54     public Ejb() {
55         this(Common.USE_DEFAULT_VALUES);
56     }
57
58     public Ejb(int options)
59     {
60         super(comparators, new org.netbeans.modules.schema2beans.Version(1, 2, 0));
61         // Properties (see root bean comments for the bean graph)
62
this.createProperty("ejb-name", // NOI18N
63
EJB_NAME,
64             Common.TYPE_1 | Common.TYPE_STRING | Common.TYPE_KEY,
65             String JavaDoc.class);
66         this.createProperty("jndi-name", // NOI18N
67
JNDI_NAME,
68             Common.TYPE_0_1 | Common.TYPE_STRING | Common.TYPE_KEY,
69             String JavaDoc.class);
70         this.createProperty("ejb-ref", // NOI18N
71
EJB_REF,
72             Common.TYPE_0_N | Common.TYPE_BEAN | Common.TYPE_KEY,
73             EjbRef.class);
74         this.createProperty("resource-ref", // NOI18N
75
RESOURCE_REF,
76             Common.TYPE_0_N | Common.TYPE_BEAN | Common.TYPE_KEY,
77             ResourceRef.class);
78         this.createProperty("resource-env-ref", // NOI18N
79
RESOURCE_ENV_REF,
80             Common.TYPE_0_N | Common.TYPE_BEAN | Common.TYPE_KEY,
81             ResourceEnvRef.class);
82         this.createProperty("service-ref", // NOI18N
83
SERVICE_REF,
84             Common.TYPE_0_N | Common.TYPE_BEAN | Common.TYPE_KEY,
85             ServiceRef.class);
86         this.createProperty("pass-by-reference", // NOI18N
87
PASS_BY_REFERENCE,
88             Common.TYPE_0_1 | Common.TYPE_STRING | Common.TYPE_KEY,
89             String JavaDoc.class);
90         this.createProperty("cmp", // NOI18N
91
CMP,
92             Common.TYPE_0_1 | Common.TYPE_BEAN | Common.TYPE_KEY,
93             Cmp.class);
94         this.createProperty("principal", // NOI18N
95
PRINCIPAL,
96             Common.TYPE_0_1 | Common.TYPE_BEAN | Common.TYPE_KEY,
97             Principal.class);
98         this.createProperty("mdb-connection-factory", // NOI18N
99
MDB_CONNECTION_FACTORY,
100             Common.TYPE_0_1 | Common.TYPE_BEAN | Common.TYPE_KEY,
101             MdbConnectionFactory.class);
102         this.createProperty("jms-durable-subscription-name", // NOI18N
103
JMS_DURABLE_SUBSCRIPTION_NAME,
104             Common.TYPE_0_1 | Common.TYPE_STRING | Common.TYPE_KEY,
105             String JavaDoc.class);
106         this.createProperty("jms-max-messages-load", // NOI18N
107
JMS_MAX_MESSAGES_LOAD,
108             Common.TYPE_0_1 | Common.TYPE_STRING | Common.TYPE_KEY,
109             String JavaDoc.class);
110         this.createProperty("ior-security-config", // NOI18N
111
IOR_SECURITY_CONFIG,
112             Common.TYPE_0_1 | Common.TYPE_BEAN | Common.TYPE_KEY,
113             IorSecurityConfig.class);
114         this.createProperty("is-read-only-bean", // NOI18N
115
IS_READ_ONLY_BEAN,
116             Common.TYPE_0_1 | Common.TYPE_STRING | Common.TYPE_KEY,
117             String JavaDoc.class);
118         this.createProperty("refresh-period-in-seconds", // NOI18N
119
REFRESH_PERIOD_IN_SECONDS,
120             Common.TYPE_0_1 | Common.TYPE_STRING | Common.TYPE_KEY,
121             String JavaDoc.class);
122         this.createProperty("commit-option", // NOI18N
123
COMMIT_OPTION,
124             Common.TYPE_0_1 | Common.TYPE_STRING | Common.TYPE_KEY,
125             String JavaDoc.class);
126         this.createProperty("cmt-timeout-in-seconds", // NOI18N
127
CMT_TIMEOUT_IN_SECONDS,
128             Common.TYPE_0_1 | Common.TYPE_STRING | Common.TYPE_KEY,
129             String JavaDoc.class);
130         this.createProperty("use-thread-pool-id", // NOI18N
131
USE_THREAD_POOL_ID,
132             Common.TYPE_0_1 | Common.TYPE_STRING | Common.TYPE_KEY,
133             String JavaDoc.class);
134         this.createProperty("gen-classes", // NOI18N
135
GEN_CLASSES,
136             Common.TYPE_0_1 | Common.TYPE_BEAN | Common.TYPE_KEY,
137             GenClasses.class);
138         this.createProperty("bean-pool", // NOI18N
139
BEAN_POOL,
140             Common.TYPE_0_1 | Common.TYPE_BEAN | Common.TYPE_KEY,
141             BeanPool.class);
142         this.createProperty("bean-cache", // NOI18N
143
BEAN_CACHE,
144             Common.TYPE_0_1 | Common.TYPE_BEAN | Common.TYPE_KEY,
145             BeanCache.class);
146         this.createProperty("mdb-resource-adapter", // NOI18N
147
MDB_RESOURCE_ADAPTER,
148             Common.TYPE_0_1 | Common.TYPE_BEAN | Common.TYPE_KEY,
149             MdbResourceAdapter.class);
150         this.createProperty("webservice-endpoint", // NOI18N
151
WEBSERVICE_ENDPOINT,
152             Common.TYPE_0_N | Common.TYPE_BEAN | Common.TYPE_KEY,
153             WebserviceEndpoint.class);
154         this.createProperty("flush-at-end-of-method", // NOI18N
155
FLUSH_AT_END_OF_METHOD,
156             Common.TYPE_0_1 | Common.TYPE_BEAN | Common.TYPE_KEY,
157             FlushAtEndOfMethod.class);
158         this.createProperty("checkpointed-methods", // NOI18N
159
CHECKPOINTED_METHODS,
160             Common.TYPE_0_1 | Common.TYPE_STRING | Common.TYPE_KEY,
161             String JavaDoc.class);
162         this.createProperty("checkpoint-at-end-of-method", // NOI18N
163
CHECKPOINT_AT_END_OF_METHOD,
164             Common.TYPE_0_1 | Common.TYPE_BEAN | Common.TYPE_KEY,
165             CheckpointAtEndOfMethod.class);
166         this.initialize(options);
167     }
168
169     // Setting the default values of the properties
170
void initialize(int options)
171     {
172                                             
173     }
174
175     // This attribute is optional
176
public void setAvailabilityEnabled(java.lang.String JavaDoc value) {
177         setAttributeValue(AVAILABILITYENABLED, value);
178     }
179
180     //
181
public java.lang.String JavaDoc getAvailabilityEnabled() {
182         return getAttributeValue(AVAILABILITYENABLED);
183     }
184
185     // This attribute is mandatory
186
public void setEjbName(String JavaDoc value) {
187         this.setValue(EJB_NAME, value);
188     }
189
190     //
191
public String JavaDoc getEjbName() {
192         return (String JavaDoc)this.getValue(EJB_NAME);
193     }
194
195     // This attribute is optional
196
public void setJndiName(String JavaDoc value) {
197         this.setValue(JNDI_NAME, value);
198     }
199
200     //
201
public String JavaDoc getJndiName() {
202         return (String JavaDoc)this.getValue(JNDI_NAME);
203     }
204
205     // This attribute is an array, possibly empty
206
public void setEjbRef(int index, EjbRef value) {
207         this.setValue(EJB_REF, index, value);
208     }
209
210     //
211
public EjbRef getEjbRef(int index) {
212         return (EjbRef)this.getValue(EJB_REF, index);
213     }
214
215     // This attribute is an array, possibly empty
216
public void setEjbRef(EjbRef[] value) {
217         this.setValue(EJB_REF, value);
218     }
219
220     //
221
public EjbRef[] getEjbRef() {
222         return (EjbRef[])this.getValues(EJB_REF);
223     }
224
225     // Return the number of properties
226
public int sizeEjbRef() {
227         return this.size(EJB_REF);
228     }
229
230     // Add a new element returning its index in the list
231
public int addEjbRef(EjbRef value) {
232         return this.addValue(EJB_REF, value);
233     }
234
235     //
236
// Remove an element using its reference
237
// Returns the index the element had in the list
238
//
239
public int removeEjbRef(EjbRef value) {
240         return this.removeValue(EJB_REF, value);
241     }
242
243     // This attribute is an array, possibly empty
244
public void setResourceRef(int index, ResourceRef value) {
245         this.setValue(RESOURCE_REF, index, value);
246     }
247
248     //
249
public ResourceRef getResourceRef(int index) {
250         return (ResourceRef)this.getValue(RESOURCE_REF, index);
251     }
252
253     // This attribute is an array, possibly empty
254
public void setResourceRef(ResourceRef[] value) {
255         this.setValue(RESOURCE_REF, value);
256     }
257
258     //
259
public ResourceRef[] getResourceRef() {
260         return (ResourceRef[])this.getValues(RESOURCE_REF);
261     }
262
263     // Return the number of properties
264
public int sizeResourceRef() {
265         return this.size(RESOURCE_REF);
266     }
267
268     // Add a new element returning its index in the list
269
public int addResourceRef(ResourceRef value) {
270         return this.addValue(RESOURCE_REF, value);
271     }
272
273     //
274
// Remove an element using its reference
275
// Returns the index the element had in the list
276
//
277
public int removeResourceRef(ResourceRef value) {
278         return this.removeValue(RESOURCE_REF, value);
279     }
280
281     // This attribute is an array, possibly empty
282
public void setResourceEnvRef(int index, ResourceEnvRef value) {
283         this.setValue(RESOURCE_ENV_REF, index, value);
284     }
285
286     //
287
public ResourceEnvRef getResourceEnvRef(int index) {
288         return (ResourceEnvRef)this.getValue(RESOURCE_ENV_REF, index);
289     }
290
291     // This attribute is an array, possibly empty
292
public void setResourceEnvRef(ResourceEnvRef[] value) {
293         this.setValue(RESOURCE_ENV_REF, value);
294     }
295
296     //
297
public ResourceEnvRef[] getResourceEnvRef() {
298         return (ResourceEnvRef[])this.getValues(RESOURCE_ENV_REF);
299     }
300
301     // Return the number of properties
302
public int sizeResourceEnvRef() {
303         return this.size(RESOURCE_ENV_REF);
304     }
305
306     // Add a new element returning its index in the list
307
public int addResourceEnvRef(ResourceEnvRef value) {
308         return this.addValue(RESOURCE_ENV_REF, value);
309     }
310
311     //
312
// Remove an element using its reference
313
// Returns the index the element had in the list
314
//
315
public int removeResourceEnvRef(ResourceEnvRef value) {
316         return this.removeValue(RESOURCE_ENV_REF, value);
317     }
318
319     // This attribute is an array, possibly empty
320
public void setServiceRef(int index, ServiceRef value) {
321         this.setValue(SERVICE_REF, index, value);
322     }
323
324     //
325
public ServiceRef getServiceRef(int index) {
326         return (ServiceRef)this.getValue(SERVICE_REF, index);
327     }
328
329     // This attribute is an array, possibly empty
330
public void setServiceRef(ServiceRef[] value) {
331         this.setValue(SERVICE_REF, value);
332     }
333
334     //
335
public ServiceRef[] getServiceRef() {
336         return (ServiceRef[])this.getValues(SERVICE_REF);
337     }
338
339     // Return the number of properties
340
public int sizeServiceRef() {
341         return this.size(SERVICE_REF);
342     }
343
344     // Add a new element returning its index in the list
345
public int addServiceRef(ServiceRef value) {
346         return this.addValue(SERVICE_REF, value);
347     }
348
349     //
350
// Remove an element using its reference
351
// Returns the index the element had in the list
352
//
353
public int removeServiceRef(ServiceRef value) {
354         return this.removeValue(SERVICE_REF, value);
355     }
356
357     // This attribute is optional
358
public void setPassByReference(String JavaDoc value) {
359         this.setValue(PASS_BY_REFERENCE, value);
360     }
361
362     //
363
public String JavaDoc getPassByReference() {
364         return (String JavaDoc)this.getValue(PASS_BY_REFERENCE);
365     }
366
367     // This attribute is optional
368
public void setCmp(Cmp value) {
369         this.setValue(CMP, value);
370     }
371
372     //
373
public Cmp getCmp() {
374         return (Cmp)this.getValue(CMP);
375     }
376
377     // This attribute is optional
378
public void setPrincipal(Principal value) {
379         this.setValue(PRINCIPAL, value);
380     }
381
382     //
383
public Principal getPrincipal() {
384         return (Principal)this.getValue(PRINCIPAL);
385     }
386
387     // This attribute is optional
388
public void setMdbConnectionFactory(MdbConnectionFactory value) {
389         this.setValue(MDB_CONNECTION_FACTORY, value);
390     }
391
392     //
393
public MdbConnectionFactory getMdbConnectionFactory() {
394         return (MdbConnectionFactory)this.getValue(MDB_CONNECTION_FACTORY);
395     }
396
397     // This attribute is optional
398
public void setJmsDurableSubscriptionName(String JavaDoc value) {
399         this.setValue(JMS_DURABLE_SUBSCRIPTION_NAME, value);
400     }
401
402     //
403
public String JavaDoc getJmsDurableSubscriptionName() {
404         return (String JavaDoc)this.getValue(JMS_DURABLE_SUBSCRIPTION_NAME);
405     }
406
407     // This attribute is optional
408
public void setJmsMaxMessagesLoad(String JavaDoc value) {
409         this.setValue(JMS_MAX_MESSAGES_LOAD, value);
410     }
411
412     //
413
public String JavaDoc getJmsMaxMessagesLoad() {
414         return (String JavaDoc)this.getValue(JMS_MAX_MESSAGES_LOAD);
415     }
416
417     // This attribute is optional
418
public void setIorSecurityConfig(IorSecurityConfig value) {
419         this.setValue(IOR_SECURITY_CONFIG, value);
420     }
421
422     //
423
public IorSecurityConfig getIorSecurityConfig() {
424         return (IorSecurityConfig)this.getValue(IOR_SECURITY_CONFIG);
425     }
426
427     // This attribute is optional
428
public void setIsReadOnlyBean(String JavaDoc value) {
429         this.setValue(IS_READ_ONLY_BEAN, value);
430     }
431
432     //
433
public String JavaDoc getIsReadOnlyBean() {
434         return (String JavaDoc)this.getValue(IS_READ_ONLY_BEAN);
435     }
436
437     // This attribute is optional
438
public void setRefreshPeriodInSeconds(String JavaDoc value) {
439         this.setValue(REFRESH_PERIOD_IN_SECONDS, value);
440     }
441
442     //
443
public String JavaDoc getRefreshPeriodInSeconds() {
444         return (String JavaDoc)this.getValue(REFRESH_PERIOD_IN_SECONDS);
445     }
446
447     // This attribute is optional
448
public void setCommitOption(String JavaDoc value) {
449         this.setValue(COMMIT_OPTION, value);
450     }
451
452     //
453
public String JavaDoc getCommitOption() {
454         return (String JavaDoc)this.getValue(COMMIT_OPTION);
455     }
456
457     // This attribute is optional
458
public void setCmtTimeoutInSeconds(String JavaDoc value) {
459         this.setValue(CMT_TIMEOUT_IN_SECONDS, value);
460     }
461
462     //
463
public String JavaDoc getCmtTimeoutInSeconds() {
464         return (String JavaDoc)this.getValue(CMT_TIMEOUT_IN_SECONDS);
465     }
466
467     // This attribute is optional
468
public void setUseThreadPoolId(String JavaDoc value) {
469         this.setValue(USE_THREAD_POOL_ID, value);
470     }
471
472     //
473
public String JavaDoc getUseThreadPoolId() {
474         return (String JavaDoc)this.getValue(USE_THREAD_POOL_ID);
475     }
476
477     // This attribute is optional
478
public void setGenClasses(GenClasses value) {
479         this.setValue(GEN_CLASSES, value);
480     }
481
482     //
483
public GenClasses getGenClasses() {
484         return (GenClasses)this.getValue(GEN_CLASSES);
485     }
486
487     // This attribute is optional
488
public void setBeanPool(BeanPool value) {
489         this.setValue(BEAN_POOL, value);
490     }
491
492     //
493
public BeanPool getBeanPool() {
494         return (BeanPool)this.getValue(BEAN_POOL);
495     }
496
497     // This attribute is optional
498
public void setBeanCache(BeanCache value) {
499         this.setValue(BEAN_CACHE, value);
500     }
501
502     //
503
public BeanCache getBeanCache() {
504         return (BeanCache)this.getValue(BEAN_CACHE);
505     }
506
507     // This attribute is optional
508
public void setMdbResourceAdapter(MdbResourceAdapter value) {
509         this.setValue(MDB_RESOURCE_ADAPTER, value);
510     }
511
512     //
513
public MdbResourceAdapter getMdbResourceAdapter() {
514         return (MdbResourceAdapter)this.getValue(MDB_RESOURCE_ADAPTER);
515     }
516
517     // This attribute is an array, possibly empty
518
public void setWebserviceEndpoint(int index, WebserviceEndpoint value) {
519         this.setValue(WEBSERVICE_ENDPOINT, index, value);
520     }
521
522     //
523
public WebserviceEndpoint getWebserviceEndpoint(int index) {
524         return (WebserviceEndpoint)this.getValue(WEBSERVICE_ENDPOINT, index);
525     }
526
527     // This attribute is an array, possibly empty
528
public void setWebserviceEndpoint(WebserviceEndpoint[] value) {
529         this.setValue(WEBSERVICE_ENDPOINT, value);
530     }
531
532     //
533
public WebserviceEndpoint[] getWebserviceEndpoint() {
534         return (WebserviceEndpoint[])this.getValues(WEBSERVICE_ENDPOINT);
535     }
536
537     // Return the number of properties
538
public int sizeWebserviceEndpoint() {
539         return this.size(WEBSERVICE_ENDPOINT);
540     }
541
542     // Add a new element returning its index in the list
543
public int addWebserviceEndpoint(WebserviceEndpoint value) {
544         return this.addValue(WEBSERVICE_ENDPOINT, value);
545     }
546
547     //
548
// Remove an element using its reference
549
// Returns the index the element had in the list
550
//
551
public int removeWebserviceEndpoint(WebserviceEndpoint value) {
552         return this.removeValue(WEBSERVICE_ENDPOINT, value);
553     }
554
555     // This attribute is optional
556
public void setFlushAtEndOfMethod(FlushAtEndOfMethod value) {
557         this.setValue(FLUSH_AT_END_OF_METHOD, value);
558     }
559
560     //
561
public FlushAtEndOfMethod getFlushAtEndOfMethod() {
562         return (FlushAtEndOfMethod)this.getValue(FLUSH_AT_END_OF_METHOD);
563     }
564
565     // This attribute is optional
566
public void setCheckpointedMethods(String JavaDoc value) {
567         this.setValue(CHECKPOINTED_METHODS, value);
568     }
569
570     //
571
public String JavaDoc getCheckpointedMethods() {
572         return (String JavaDoc)this.getValue(CHECKPOINTED_METHODS);
573     }
574
575     // This attribute is optional
576
public void setCheckpointAtEndOfMethod(CheckpointAtEndOfMethod value) {
577         this.setValue(CHECKPOINT_AT_END_OF_METHOD, value);
578     }
579
580     //
581
public CheckpointAtEndOfMethod getCheckpointAtEndOfMethod() {
582         return (CheckpointAtEndOfMethod)this.getValue(CHECKPOINT_AT_END_OF_METHOD);
583     }
584
585     //
586
public static void addComparator(org.netbeans.modules.schema2beans.BeanComparator c) {
587         comparators.add(c);
588     }
589
590     //
591
public static void removeComparator(org.netbeans.modules.schema2beans.BeanComparator c) {
592         comparators.remove(c);
593     }
594     public void validate() throws org.netbeans.modules.schema2beans.ValidateException {
595         boolean restrictionFailure = false;
596         // Validating property availabilityEnabled
597
if (getAvailabilityEnabled() != null) {
598         }
599         // Validating property ejbName
600
if (getEjbName() == null) {
601             throw new org.netbeans.modules.schema2beans.ValidateException("getEjbName() == null", "ejbName", this); // NOI18N
602
}
603         // Validating property jndiName
604
if (getJndiName() != null) {
605         }
606         // Validating property ejbRef
607
for (int _index = 0; _index < sizeEjbRef(); ++_index) {
608             EjbRef element = getEjbRef(_index);
609             if (element != null) {
610                 element.validate();
611             }
612         }
613         // Validating property resourceRef
614
for (int _index = 0; _index < sizeResourceRef(); ++_index) {
615             ResourceRef element = getResourceRef(_index);
616             if (element != null) {
617                 element.validate();
618             }
619         }
620         // Validating property resourceEnvRef
621
for (int _index = 0; _index < sizeResourceEnvRef(); ++_index) {
622             ResourceEnvRef element = getResourceEnvRef(_index);
623             if (element != null) {
624                 element.validate();
625             }
626         }
627         // Validating property serviceRef
628
for (int _index = 0; _index < sizeServiceRef(); ++_index) {
629             ServiceRef element = getServiceRef(_index);
630             if (element != null) {
631                 element.validate();
632             }
633         }
634         // Validating property passByReference
635
if (getPassByReference() != null) {
636         }
637         // Validating property cmp
638
if (getCmp() != null) {
639             getCmp().validate();
640         }
641         // Validating property principal
642
if (getPrincipal() != null) {
643             getPrincipal().validate();
644         }
645         // Validating property mdbConnectionFactory
646
if (getMdbConnectionFactory() != null) {
647             getMdbConnectionFactory().validate();
648         }
649         // Validating property jmsDurableSubscriptionName
650
if (getJmsDurableSubscriptionName() != null) {
651         }
652         // Validating property jmsMaxMessagesLoad
653
if (getJmsMaxMessagesLoad() != null) {
654         }
655         // Validating property iorSecurityConfig
656
if (getIorSecurityConfig() != null) {
657             getIorSecurityConfig().validate();
658         }
659         // Validating property isReadOnlyBean
660
if (getIsReadOnlyBean() != null) {
661         }
662         // Validating property refreshPeriodInSeconds
663
if (getRefreshPeriodInSeconds() != null) {
664         }
665         // Validating property commitOption
666
if (getCommitOption() != null) {
667         }
668         // Validating property cmtTimeoutInSeconds
669
if (getCmtTimeoutInSeconds() != null) {
670         }
671         // Validating property useThreadPoolId
672
if (getUseThreadPoolId() != null) {
673         }
674         // Validating property genClasses
675
if (getGenClasses() != null) {
676             getGenClasses().validate();
677         }
678         // Validating property beanPool
679
if (getBeanPool() != null) {
680             getBeanPool().validate();
681         }
682         // Validating property beanCache
683
if (getBeanCache() != null) {
684             getBeanCache().validate();
685         }
686         // Validating property mdbResourceAdapter
687
if (getMdbResourceAdapter() != null) {
688             getMdbResourceAdapter().validate();
689         }
690         // Validating property webserviceEndpoint
691
for (int _index = 0; _index < sizeWebserviceEndpoint(); ++_index) {
692             WebserviceEndpoint element = getWebserviceEndpoint(_index);
693             if (element != null) {
694                 element.validate();
695             }
696         }
697         // Validating property flushAtEndOfMethod
698
if (getFlushAtEndOfMethod() != null) {
699             getFlushAtEndOfMethod().validate();
700         }
701         // Validating property checkpointedMethods
702
if (getCheckpointedMethods() != null) {
703         }
704         // Validating property checkpointAtEndOfMethod
705
if (getCheckpointAtEndOfMethod() != null) {
706             getCheckpointAtEndOfMethod().validate();
707         }
708     }
709
710     // Dump the content of this bean returning it as a String
711
public void dump(StringBuffer JavaDoc str, String JavaDoc indent){
712         String JavaDoc s;
713         Object JavaDoc o;
714         org.netbeans.modules.schema2beans.BaseBean n;
715         str.append(indent);
716         str.append("EjbName"); // NOI18N
717
str.append(indent+"\t"); // NOI18N
718
str.append("<"); // NOI18N
719
s = this.getEjbName();
720         str.append((s==null?"null":s.trim())); // NOI18N
721
str.append(">\n"); // NOI18N
722
this.dumpAttributes(EJB_NAME, 0, str, indent);
723
724         str.append(indent);
725         str.append("JndiName"); // NOI18N
726
str.append(indent+"\t"); // NOI18N
727
str.append("<"); // NOI18N
728
s = this.getJndiName();
729         str.append((s==null?"null":s.trim())); // NOI18N
730
str.append(">\n"); // NOI18N
731
this.dumpAttributes(JNDI_NAME, 0, str, indent);
732
733         str.append(indent);
734         str.append("EjbRef["+this.sizeEjbRef()+"]"); // NOI18N
735
for(int i=0; i<this.sizeEjbRef(); i++)
736         {
737             str.append(indent+"\t");
738             str.append("#"+i+":");
739             n = (org.netbeans.modules.schema2beans.BaseBean) this.getEjbRef(i);
740             if (n != null)
741                 n.dump(str, indent + "\t"); // NOI18N
742
else
743                 str.append(indent+"\tnull"); // NOI18N
744
this.dumpAttributes(EJB_REF, i, str, indent);
745         }
746
747         str.append(indent);
748         str.append("ResourceRef["+this.sizeResourceRef()+"]"); // NOI18N
749
for(int i=0; i<this.sizeResourceRef(); i++)
750         {
751             str.append(indent+"\t");
752             str.append("#"+i+":");
753             n = (org.netbeans.modules.schema2beans.BaseBean) this.getResourceRef(i);
754             if (n != null)
755                 n.dump(str, indent + "\t"); // NOI18N
756
else
757                 str.append(indent+"\tnull"); // NOI18N
758
this.dumpAttributes(RESOURCE_REF, i, str, indent);
759         }
760
761         str.append(indent);
762         str.append("ResourceEnvRef["+this.sizeResourceEnvRef()+"]"); // NOI18N
763
for(int i=0; i<this.sizeResourceEnvRef(); i++)
764         {
765             str.append(indent+"\t");
766             str.append("#"+i+":");
767             n = (org.netbeans.modules.schema2beans.BaseBean) this.getResourceEnvRef(i);
768             if (n != null)
769                 n.dump(str, indent + "\t"); // NOI18N
770
else
771                 str.append(indent+"\tnull"); // NOI18N
772
this.dumpAttributes(RESOURCE_ENV_REF, i, str, indent);
773         }
774
775         str.append(indent);
776         str.append("ServiceRef["+this.sizeServiceRef()+"]"); // NOI18N
777
for(int i=0; i<this.sizeServiceRef(); i++)
778         {
779             str.append(indent+"\t");
780             str.append("#"+i+":");
781             n = (org.netbeans.modules.schema2beans.BaseBean) this.getServiceRef(i);
782             if (n != null)
783                 n.dump(str, indent + "\t"); // NOI18N
784
else
785                 str.append(indent+"\tnull"); // NOI18N
786
this.dumpAttributes(SERVICE_REF, i, str, indent);
787         }
788
789         str.append(indent);
790         str.append("PassByReference"); // NOI18N
791
str.append(indent+"\t"); // NOI18N
792
str.append("<"); // NOI18N
793
s = this.getPassByReference();
794         str.append((s==null?"null":s.trim())); // NOI18N
795
str.append(">\n"); // NOI18N
796
this.dumpAttributes(PASS_BY_REFERENCE, 0, str, indent);
797
798         str.append(indent);
799         str.append("Cmp"); // NOI18N
800
n = (org.netbeans.modules.schema2beans.BaseBean) this.getCmp();
801         if (n != null)
802             n.dump(str, indent + "\t"); // NOI18N
803
else
804             str.append(indent+"\tnull"); // NOI18N
805
this.dumpAttributes(CMP, 0, str, indent);
806
807         str.append(indent);
808         str.append("Principal"); // NOI18N
809
n = (org.netbeans.modules.schema2beans.BaseBean) this.getPrincipal();
810         if (n != null)
811             n.dump(str, indent + "\t"); // NOI18N
812
else
813             str.append(indent+"\tnull"); // NOI18N
814
this.dumpAttributes(PRINCIPAL, 0, str, indent);
815
816         str.append(indent);
817         str.append("MdbConnectionFactory"); // NOI18N
818
n = (org.netbeans.modules.schema2beans.BaseBean) this.getMdbConnectionFactory();
819         if (n != null)
820             n.dump(str, indent + "\t"); // NOI18N
821
else
822             str.append(indent+"\tnull"); // NOI18N
823
this.dumpAttributes(MDB_CONNECTION_FACTORY, 0, str, indent);
824
825         str.append(indent);
826         str.append("JmsDurableSubscriptionName"); // NOI18N
827
str.append(indent+"\t"); // NOI18N
828
str.append("<"); // NOI18N
829
s = this.getJmsDurableSubscriptionName();
830         str.append((s==null?"null":s.trim())); // NOI18N
831
str.append(">\n"); // NOI18N
832
this.dumpAttributes(JMS_DURABLE_SUBSCRIPTION_NAME, 0, str, indent);
833
834         str.append(indent);
835         str.append("JmsMaxMessagesLoad"); // NOI18N
836
str.append(indent+"\t"); // NOI18N
837
str.append("<"); // NOI18N
838
s = this.getJmsMaxMessagesLoad();
839         str.append((s==null?"null":s.trim())); // NOI18N
840
str.append(">\n"); // NOI18N
841
this.dumpAttributes(JMS_MAX_MESSAGES_LOAD, 0, str, indent);
842
843         str.append(indent);
844         str.append("IorSecurityConfig"); // NOI18N
845
n = (org.netbeans.modules.schema2beans.BaseBean) this.getIorSecurityConfig();
846         if (n != null)
847             n.dump(str, indent + "\t"); // NOI18N
848
else
849             str.append(indent+"\tnull"); // NOI18N
850
this.dumpAttributes(IOR_SECURITY_CONFIG, 0, str, indent);
851
852         str.append(indent);
853         str.append("IsReadOnlyBean"); // NOI18N
854
str.append(indent+"\t"); // NOI18N
855
str.append("<"); // NOI18N
856
s = this.getIsReadOnlyBean();
857         str.append((s==null?"null":s.trim())); // NOI18N
858
str.append(">\n"); // NOI18N
859
this.dumpAttributes(IS_READ_ONLY_BEAN, 0, str, indent);
860
861         str.append(indent);
862         str.append("RefreshPeriodInSeconds"); // NOI18N
863
str.append(indent+"\t"); // NOI18N
864
str.append("<"); // NOI18N
865
s = this.getRefreshPeriodInSeconds();
866         str.append((s==null?"null":s.trim())); // NOI18N
867
str.append(">\n"); // NOI18N
868
this.dumpAttributes(REFRESH_PERIOD_IN_SECONDS, 0, str, indent);
869
870         str.append(indent);
871         str.append("CommitOption"); // NOI18N
872
str.append(indent+"\t"); // NOI18N
873
str.append("<"); // NOI18N
874
s = this.getCommitOption();
875         str.append((s==null?"null":s.trim())); // NOI18N
876
str.append(">\n"); // NOI18N
877
this.dumpAttributes(COMMIT_OPTION, 0, str, indent);
878
879         str.append(indent);
880         str.append("CmtTimeoutInSeconds"); // NOI18N
881
str.append(indent+"\t"); // NOI18N
882
str.append("<"); // NOI18N
883
s = this.getCmtTimeoutInSeconds();
884         str.append((s==null?"null":s.trim())); // NOI18N
885
str.append(">\n"); // NOI18N
886
this.dumpAttributes(CMT_TIMEOUT_IN_SECONDS, 0, str, indent);
887
888         str.append(indent);
889         str.append("UseThreadPoolId"); // NOI18N
890
str.append(indent+"\t"); // NOI18N
891
str.append("<"); // NOI18N
892
s = this.getUseThreadPoolId();
893         str.append((s==null?"null":s.trim())); // NOI18N
894
str.append(">\n"); // NOI18N
895
this.dumpAttributes(USE_THREAD_POOL_ID, 0, str, indent);
896
897         str.append(indent);
898         str.append("GenClasses"); // NOI18N
899
n = (org.netbeans.modules.schema2beans.BaseBean) this.getGenClasses();
900         if (n != null)
901             n.dump(str, indent + "\t"); // NOI18N
902
else
903             str.append(indent+"\tnull"); // NOI18N
904
this.dumpAttributes(GEN_CLASSES, 0, str, indent);
905
906         str.append(indent);
907         str.append("BeanPool"); // NOI18N
908
n = (org.netbeans.modules.schema2beans.BaseBean) this.getBeanPool();
909         if (n != null)
910             n.dump(str, indent + "\t"); // NOI18N
911
else
912             str.append(indent+"\tnull"); // NOI18N
913
this.dumpAttributes(BEAN_POOL, 0, str, indent);
914
915         str.append(indent);
916         str.append("BeanCache"); // NOI18N
917
n = (org.netbeans.modules.schema2beans.BaseBean) this.getBeanCache();
918         if (n != null)
919             n.dump(str, indent + "\t"); // NOI18N
920
else
921             str.append(indent+"\tnull"); // NOI18N
922
this.dumpAttributes(BEAN_CACHE, 0, str, indent);
923
924         str.append(indent);
925         str.append("MdbResourceAdapter"); // NOI18N
926
n = (org.netbeans.modules.schema2beans.BaseBean) this.getMdbResourceAdapter();
927         if (n != null)
928             n.dump(str, indent + "\t"); // NOI18N
929
else
930             str.append(indent+"\tnull"); // NOI18N
931
this.dumpAttributes(MDB_RESOURCE_ADAPTER, 0, str, indent);
932
933         str.append(indent);
934         str.append("WebserviceEndpoint["+this.sizeWebserviceEndpoint()+"]"); // NOI18N
935
for(int i=0; i<this.sizeWebserviceEndpoint(); i++)
936         {
937             str.append(indent+"\t");
938             str.append("#"+i+":");
939             n = (org.netbeans.modules.schema2beans.BaseBean) this.getWebserviceEndpoint(i);
940             if (n != null)
941                 n.dump(str, indent + "\t"); // NOI18N
942
else
943                 str.append(indent+"\tnull"); // NOI18N
944
this.dumpAttributes(WEBSERVICE_ENDPOINT, i, str, indent);
945         }
946
947         str.append(indent);
948         str.append("FlushAtEndOfMethod"); // NOI18N
949
n = (org.netbeans.modules.schema2beans.BaseBean) this.getFlushAtEndOfMethod();
950         if (n != null)
951             n.dump(str, indent + "\t"); // NOI18N
952
else
953             str.append(indent+"\tnull"); // NOI18N
954
this.dumpAttributes(FLUSH_AT_END_OF_METHOD, 0, str, indent);
955
956         str.append(indent);
957         str.append("CheckpointedMethods"); // NOI18N
958
str.append(indent+"\t"); // NOI18N
959
str.append("<"); // NOI18N
960
s = this.getCheckpointedMethods();
961         str.append((s==null?"null":s.trim())); // NOI18N
962
str.append(">\n"); // NOI18N
963
this.dumpAttributes(CHECKPOINTED_METHODS, 0, str, indent);
964
965         str.append(indent);
966         str.append("CheckpointAtEndOfMethod"); // NOI18N
967
n = (org.netbeans.modules.schema2beans.BaseBean) this.getCheckpointAtEndOfMethod();
968         if (n != null)
969             n.dump(str, indent + "\t"); // NOI18N
970
else
971             str.append(indent+"\tnull"); // NOI18N
972
this.dumpAttributes(CHECKPOINT_AT_END_OF_METHOD, 0, str, indent);
973
974     }
975     public String JavaDoc dumpBeanNode(){
976         StringBuffer JavaDoc str = new StringBuffer JavaDoc();
977         str.append("Ejb\n"); // NOI18N
978
this.dump(str, "\n "); // NOI18N
979
return str.toString();
980     }}
981
982 // END_NOI18N
983

984
985 /*
986  * The contents of this file are subject to the terms
987  * of the Common Development and Distribution License
988  * (the License). You may not use this file except in
989  * compliance with the License.
990  *
991  * You can obtain a copy of the license at
992  * https://glassfish.dev.java.net/public/CDDLv1.0.html or
993  * glassfish/bootstrap/legal/CDDLv1.0.txt.
994  * See the License for the specific language governing
995  * permissions and limitations under the License.
996  *
997  * When distributing Covered Code, include this CDDL
998  * Header Notice in each file and include the License file
999  * at glassfish/bootstrap/legal/CDDLv1.0.txt.
1000 * If applicable, add the following below the CDDL Header,
1001 * with the fields enclosed by brackets [] replaced by
1002 * you own identifying information:
1003 * "Portions Copyrighted [year] [name of copyright owner]"
1004 *
1005 * Copyright 2006 Sun Microsystems, Inc. All rights reserved.
1006 */

1007
Popular Tags