001    /*
002     * XML Type:  tssType
003     * Namespace: http://openejb.apache.org/xml/ns/corba-tss-config-2.1
004     * Java type: org.apache.geronimo.corba.xbeans.csiv2.tss.TSSTssType
005     *
006     * Automatically generated - do not modify.
007     */
008    package org.apache.geronimo.corba.xbeans.csiv2.tss.impl;
009    /**
010     * An XML tssType(@http://openejb.apache.org/xml/ns/corba-tss-config-2.1).
011     *
012     * This is a complex type.
013     */
014    public class TSSTssTypeImpl extends org.apache.xmlbeans.impl.values.XmlComplexContentImpl implements org.apache.geronimo.corba.xbeans.csiv2.tss.TSSTssType
015    {
016        
017        public TSSTssTypeImpl(org.apache.xmlbeans.SchemaType sType)
018        {
019            super(sType);
020        }
021        
022        private static final javax.xml.namespace.QName DESCRIPTION$0 = 
023            new javax.xml.namespace.QName("http://openejb.apache.org/xml/ns/corba-tss-config-2.1", "description");
024        private static final javax.xml.namespace.QName SSL$2 = 
025            new javax.xml.namespace.QName("http://openejb.apache.org/xml/ns/corba-tss-config-2.1", "SSL");
026        private static final javax.xml.namespace.QName SECIOP$4 = 
027            new javax.xml.namespace.QName("http://openejb.apache.org/xml/ns/corba-tss-config-2.1", "SECIOP");
028        private static final javax.xml.namespace.QName COMPOUNDSECMECHTYPELIST$6 = 
029            new javax.xml.namespace.QName("http://openejb.apache.org/xml/ns/corba-tss-config-2.1", "compoundSecMechTypeList");
030        private static final javax.xml.namespace.QName INHERIT$8 = 
031            new javax.xml.namespace.QName("", "inherit");
032        
033        
034        /**
035         * Gets array of all "description" elements
036         */
037        public org.apache.geronimo.corba.xbeans.csiv2.tss.TSSDescriptionType[] getDescriptionArray()
038        {
039            synchronized (monitor())
040            {
041                check_orphaned();
042                java.util.List targetList = new java.util.ArrayList();
043                get_store().find_all_element_users(DESCRIPTION$0, targetList);
044                org.apache.geronimo.corba.xbeans.csiv2.tss.TSSDescriptionType[] result = new org.apache.geronimo.corba.xbeans.csiv2.tss.TSSDescriptionType[targetList.size()];
045                targetList.toArray(result);
046                return result;
047            }
048        }
049        
050        /**
051         * Gets ith "description" element
052         */
053        public org.apache.geronimo.corba.xbeans.csiv2.tss.TSSDescriptionType getDescriptionArray(int i)
054        {
055            synchronized (monitor())
056            {
057                check_orphaned();
058                org.apache.geronimo.corba.xbeans.csiv2.tss.TSSDescriptionType target = null;
059                target = (org.apache.geronimo.corba.xbeans.csiv2.tss.TSSDescriptionType)get_store().find_element_user(DESCRIPTION$0, i);
060                if (target == null)
061                {
062                    throw new IndexOutOfBoundsException();
063                }
064                return target;
065            }
066        }
067        
068        /**
069         * Returns number of "description" element
070         */
071        public int sizeOfDescriptionArray()
072        {
073            synchronized (monitor())
074            {
075                check_orphaned();
076                return get_store().count_elements(DESCRIPTION$0);
077            }
078        }
079        
080        /**
081         * Sets array of all "description" element
082         */
083        public void setDescriptionArray(org.apache.geronimo.corba.xbeans.csiv2.tss.TSSDescriptionType[] descriptionArray)
084        {
085            synchronized (monitor())
086            {
087                check_orphaned();
088                arraySetterHelper(descriptionArray, DESCRIPTION$0);
089            }
090        }
091        
092        /**
093         * Sets ith "description" element
094         */
095        public void setDescriptionArray(int i, org.apache.geronimo.corba.xbeans.csiv2.tss.TSSDescriptionType description)
096        {
097            synchronized (monitor())
098            {
099                check_orphaned();
100                org.apache.geronimo.corba.xbeans.csiv2.tss.TSSDescriptionType target = null;
101                target = (org.apache.geronimo.corba.xbeans.csiv2.tss.TSSDescriptionType)get_store().find_element_user(DESCRIPTION$0, i);
102                if (target == null)
103                {
104                    throw new IndexOutOfBoundsException();
105                }
106                target.set(description);
107            }
108        }
109        
110        /**
111         * Inserts and returns a new empty value (as xml) as the ith "description" element
112         */
113        public org.apache.geronimo.corba.xbeans.csiv2.tss.TSSDescriptionType insertNewDescription(int i)
114        {
115            synchronized (monitor())
116            {
117                check_orphaned();
118                org.apache.geronimo.corba.xbeans.csiv2.tss.TSSDescriptionType target = null;
119                target = (org.apache.geronimo.corba.xbeans.csiv2.tss.TSSDescriptionType)get_store().insert_element_user(DESCRIPTION$0, i);
120                return target;
121            }
122        }
123        
124        /**
125         * Appends and returns a new empty value (as xml) as the last "description" element
126         */
127        public org.apache.geronimo.corba.xbeans.csiv2.tss.TSSDescriptionType addNewDescription()
128        {
129            synchronized (monitor())
130            {
131                check_orphaned();
132                org.apache.geronimo.corba.xbeans.csiv2.tss.TSSDescriptionType target = null;
133                target = (org.apache.geronimo.corba.xbeans.csiv2.tss.TSSDescriptionType)get_store().add_element_user(DESCRIPTION$0);
134                return target;
135            }
136        }
137        
138        /**
139         * Removes the ith "description" element
140         */
141        public void removeDescription(int i)
142        {
143            synchronized (monitor())
144            {
145                check_orphaned();
146                get_store().remove_element(DESCRIPTION$0, i);
147            }
148        }
149        
150        /**
151         * Gets the "SSL" element
152         */
153        public org.apache.geronimo.corba.xbeans.csiv2.tss.TSSSSLType getSSL()
154        {
155            synchronized (monitor())
156            {
157                check_orphaned();
158                org.apache.geronimo.corba.xbeans.csiv2.tss.TSSSSLType target = null;
159                target = (org.apache.geronimo.corba.xbeans.csiv2.tss.TSSSSLType)get_store().find_element_user(SSL$2, 0);
160                if (target == null)
161                {
162                    return null;
163                }
164                return target;
165            }
166        }
167        
168        /**
169         * True if has "SSL" element
170         */
171        public boolean isSetSSL()
172        {
173            synchronized (monitor())
174            {
175                check_orphaned();
176                return get_store().count_elements(SSL$2) != 0;
177            }
178        }
179        
180        /**
181         * Sets the "SSL" element
182         */
183        public void setSSL(org.apache.geronimo.corba.xbeans.csiv2.tss.TSSSSLType ssl)
184        {
185            synchronized (monitor())
186            {
187                check_orphaned();
188                org.apache.geronimo.corba.xbeans.csiv2.tss.TSSSSLType target = null;
189                target = (org.apache.geronimo.corba.xbeans.csiv2.tss.TSSSSLType)get_store().find_element_user(SSL$2, 0);
190                if (target == null)
191                {
192                    target = (org.apache.geronimo.corba.xbeans.csiv2.tss.TSSSSLType)get_store().add_element_user(SSL$2);
193                }
194                target.set(ssl);
195            }
196        }
197        
198        /**
199         * Appends and returns a new empty "SSL" element
200         */
201        public org.apache.geronimo.corba.xbeans.csiv2.tss.TSSSSLType addNewSSL()
202        {
203            synchronized (monitor())
204            {
205                check_orphaned();
206                org.apache.geronimo.corba.xbeans.csiv2.tss.TSSSSLType target = null;
207                target = (org.apache.geronimo.corba.xbeans.csiv2.tss.TSSSSLType)get_store().add_element_user(SSL$2);
208                return target;
209            }
210        }
211        
212        /**
213         * Unsets the "SSL" element
214         */
215        public void unsetSSL()
216        {
217            synchronized (monitor())
218            {
219                check_orphaned();
220                get_store().remove_element(SSL$2, 0);
221            }
222        }
223        
224        /**
225         * Gets the "SECIOP" element
226         */
227        public org.apache.geronimo.corba.xbeans.csiv2.tss.TSSSECIOPType getSECIOP()
228        {
229            synchronized (monitor())
230            {
231                check_orphaned();
232                org.apache.geronimo.corba.xbeans.csiv2.tss.TSSSECIOPType target = null;
233                target = (org.apache.geronimo.corba.xbeans.csiv2.tss.TSSSECIOPType)get_store().find_element_user(SECIOP$4, 0);
234                if (target == null)
235                {
236                    return null;
237                }
238                return target;
239            }
240        }
241        
242        /**
243         * True if has "SECIOP" element
244         */
245        public boolean isSetSECIOP()
246        {
247            synchronized (monitor())
248            {
249                check_orphaned();
250                return get_store().count_elements(SECIOP$4) != 0;
251            }
252        }
253        
254        /**
255         * Sets the "SECIOP" element
256         */
257        public void setSECIOP(org.apache.geronimo.corba.xbeans.csiv2.tss.TSSSECIOPType seciop)
258        {
259            synchronized (monitor())
260            {
261                check_orphaned();
262                org.apache.geronimo.corba.xbeans.csiv2.tss.TSSSECIOPType target = null;
263                target = (org.apache.geronimo.corba.xbeans.csiv2.tss.TSSSECIOPType)get_store().find_element_user(SECIOP$4, 0);
264                if (target == null)
265                {
266                    target = (org.apache.geronimo.corba.xbeans.csiv2.tss.TSSSECIOPType)get_store().add_element_user(SECIOP$4);
267                }
268                target.set(seciop);
269            }
270        }
271        
272        /**
273         * Appends and returns a new empty "SECIOP" element
274         */
275        public org.apache.geronimo.corba.xbeans.csiv2.tss.TSSSECIOPType addNewSECIOP()
276        {
277            synchronized (monitor())
278            {
279                check_orphaned();
280                org.apache.geronimo.corba.xbeans.csiv2.tss.TSSSECIOPType target = null;
281                target = (org.apache.geronimo.corba.xbeans.csiv2.tss.TSSSECIOPType)get_store().add_element_user(SECIOP$4);
282                return target;
283            }
284        }
285        
286        /**
287         * Unsets the "SECIOP" element
288         */
289        public void unsetSECIOP()
290        {
291            synchronized (monitor())
292            {
293                check_orphaned();
294                get_store().remove_element(SECIOP$4, 0);
295            }
296        }
297        
298        /**
299         * Gets the "compoundSecMechTypeList" element
300         */
301        public org.apache.geronimo.corba.xbeans.csiv2.tss.TSSTssType.CompoundSecMechTypeList getCompoundSecMechTypeList()
302        {
303            synchronized (monitor())
304            {
305                check_orphaned();
306                org.apache.geronimo.corba.xbeans.csiv2.tss.TSSTssType.CompoundSecMechTypeList target = null;
307                target = (org.apache.geronimo.corba.xbeans.csiv2.tss.TSSTssType.CompoundSecMechTypeList)get_store().find_element_user(COMPOUNDSECMECHTYPELIST$6, 0);
308                if (target == null)
309                {
310                    return null;
311                }
312                return target;
313            }
314        }
315        
316        /**
317         * True if has "compoundSecMechTypeList" element
318         */
319        public boolean isSetCompoundSecMechTypeList()
320        {
321            synchronized (monitor())
322            {
323                check_orphaned();
324                return get_store().count_elements(COMPOUNDSECMECHTYPELIST$6) != 0;
325            }
326        }
327        
328        /**
329         * Sets the "compoundSecMechTypeList" element
330         */
331        public void setCompoundSecMechTypeList(org.apache.geronimo.corba.xbeans.csiv2.tss.TSSTssType.CompoundSecMechTypeList compoundSecMechTypeList)
332        {
333            synchronized (monitor())
334            {
335                check_orphaned();
336                org.apache.geronimo.corba.xbeans.csiv2.tss.TSSTssType.CompoundSecMechTypeList target = null;
337                target = (org.apache.geronimo.corba.xbeans.csiv2.tss.TSSTssType.CompoundSecMechTypeList)get_store().find_element_user(COMPOUNDSECMECHTYPELIST$6, 0);
338                if (target == null)
339                {
340                    target = (org.apache.geronimo.corba.xbeans.csiv2.tss.TSSTssType.CompoundSecMechTypeList)get_store().add_element_user(COMPOUNDSECMECHTYPELIST$6);
341                }
342                target.set(compoundSecMechTypeList);
343            }
344        }
345        
346        /**
347         * Appends and returns a new empty "compoundSecMechTypeList" element
348         */
349        public org.apache.geronimo.corba.xbeans.csiv2.tss.TSSTssType.CompoundSecMechTypeList addNewCompoundSecMechTypeList()
350        {
351            synchronized (monitor())
352            {
353                check_orphaned();
354                org.apache.geronimo.corba.xbeans.csiv2.tss.TSSTssType.CompoundSecMechTypeList target = null;
355                target = (org.apache.geronimo.corba.xbeans.csiv2.tss.TSSTssType.CompoundSecMechTypeList)get_store().add_element_user(COMPOUNDSECMECHTYPELIST$6);
356                return target;
357            }
358        }
359        
360        /**
361         * Unsets the "compoundSecMechTypeList" element
362         */
363        public void unsetCompoundSecMechTypeList()
364        {
365            synchronized (monitor())
366            {
367                check_orphaned();
368                get_store().remove_element(COMPOUNDSECMECHTYPELIST$6, 0);
369            }
370        }
371        
372        /**
373         * Gets the "inherit" attribute
374         */
375        public boolean getInherit()
376        {
377            synchronized (monitor())
378            {
379                check_orphaned();
380                org.apache.xmlbeans.SimpleValue target = null;
381                target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(INHERIT$8);
382                if (target == null)
383                {
384                    target = (org.apache.xmlbeans.SimpleValue)get_default_attribute_value(INHERIT$8);
385                }
386                if (target == null)
387                {
388                    return false;
389                }
390                return target.getBooleanValue();
391            }
392        }
393        
394        /**
395         * Gets (as xml) the "inherit" attribute
396         */
397        public org.apache.xmlbeans.XmlBoolean xgetInherit()
398        {
399            synchronized (monitor())
400            {
401                check_orphaned();
402                org.apache.xmlbeans.XmlBoolean target = null;
403                target = (org.apache.xmlbeans.XmlBoolean)get_store().find_attribute_user(INHERIT$8);
404                if (target == null)
405                {
406                    target = (org.apache.xmlbeans.XmlBoolean)get_default_attribute_value(INHERIT$8);
407                }
408                return target;
409            }
410        }
411        
412        /**
413         * True if has "inherit" attribute
414         */
415        public boolean isSetInherit()
416        {
417            synchronized (monitor())
418            {
419                check_orphaned();
420                return get_store().find_attribute_user(INHERIT$8) != null;
421            }
422        }
423        
424        /**
425         * Sets the "inherit" attribute
426         */
427        public void setInherit(boolean inherit)
428        {
429            synchronized (monitor())
430            {
431                check_orphaned();
432                org.apache.xmlbeans.SimpleValue target = null;
433                target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(INHERIT$8);
434                if (target == null)
435                {
436                    target = (org.apache.xmlbeans.SimpleValue)get_store().add_attribute_user(INHERIT$8);
437                }
438                target.setBooleanValue(inherit);
439            }
440        }
441        
442        /**
443         * Sets (as xml) the "inherit" attribute
444         */
445        public void xsetInherit(org.apache.xmlbeans.XmlBoolean inherit)
446        {
447            synchronized (monitor())
448            {
449                check_orphaned();
450                org.apache.xmlbeans.XmlBoolean target = null;
451                target = (org.apache.xmlbeans.XmlBoolean)get_store().find_attribute_user(INHERIT$8);
452                if (target == null)
453                {
454                    target = (org.apache.xmlbeans.XmlBoolean)get_store().add_attribute_user(INHERIT$8);
455                }
456                target.set(inherit);
457            }
458        }
459        
460        /**
461         * Unsets the "inherit" attribute
462         */
463        public void unsetInherit()
464        {
465            synchronized (monitor())
466            {
467                check_orphaned();
468                get_store().remove_attribute(INHERIT$8);
469            }
470        }
471        /**
472         * An XML compoundSecMechTypeList(@http://openejb.apache.org/xml/ns/corba-tss-config-2.1).
473         *
474         * This is a complex type.
475         */
476        public static class CompoundSecMechTypeListImpl extends org.apache.xmlbeans.impl.values.XmlComplexContentImpl implements org.apache.geronimo.corba.xbeans.csiv2.tss.TSSTssType.CompoundSecMechTypeList
477        {
478            
479            public CompoundSecMechTypeListImpl(org.apache.xmlbeans.SchemaType sType)
480            {
481                super(sType);
482            }
483            
484            private static final javax.xml.namespace.QName COMPOUNDSECMECH$0 = 
485                new javax.xml.namespace.QName("http://openejb.apache.org/xml/ns/corba-tss-config-2.1", "compoundSecMech");
486            private static final javax.xml.namespace.QName STATEFUL$2 = 
487                new javax.xml.namespace.QName("", "stateful");
488            
489            
490            /**
491             * Gets array of all "compoundSecMech" elements
492             */
493            public org.apache.geronimo.corba.xbeans.csiv2.tss.TSSCompoundSecMechType[] getCompoundSecMechArray()
494            {
495                synchronized (monitor())
496                {
497                    check_orphaned();
498                    java.util.List targetList = new java.util.ArrayList();
499                    get_store().find_all_element_users(COMPOUNDSECMECH$0, targetList);
500                    org.apache.geronimo.corba.xbeans.csiv2.tss.TSSCompoundSecMechType[] result = new org.apache.geronimo.corba.xbeans.csiv2.tss.TSSCompoundSecMechType[targetList.size()];
501                    targetList.toArray(result);
502                    return result;
503                }
504            }
505            
506            /**
507             * Gets ith "compoundSecMech" element
508             */
509            public org.apache.geronimo.corba.xbeans.csiv2.tss.TSSCompoundSecMechType getCompoundSecMechArray(int i)
510            {
511                synchronized (monitor())
512                {
513                    check_orphaned();
514                    org.apache.geronimo.corba.xbeans.csiv2.tss.TSSCompoundSecMechType target = null;
515                    target = (org.apache.geronimo.corba.xbeans.csiv2.tss.TSSCompoundSecMechType)get_store().find_element_user(COMPOUNDSECMECH$0, i);
516                    if (target == null)
517                    {
518                        throw new IndexOutOfBoundsException();
519                    }
520                    return target;
521                }
522            }
523            
524            /**
525             * Returns number of "compoundSecMech" element
526             */
527            public int sizeOfCompoundSecMechArray()
528            {
529                synchronized (monitor())
530                {
531                    check_orphaned();
532                    return get_store().count_elements(COMPOUNDSECMECH$0);
533                }
534            }
535            
536            /**
537             * Sets array of all "compoundSecMech" element
538             */
539            public void setCompoundSecMechArray(org.apache.geronimo.corba.xbeans.csiv2.tss.TSSCompoundSecMechType[] compoundSecMechArray)
540            {
541                synchronized (monitor())
542                {
543                    check_orphaned();
544                    arraySetterHelper(compoundSecMechArray, COMPOUNDSECMECH$0);
545                }
546            }
547            
548            /**
549             * Sets ith "compoundSecMech" element
550             */
551            public void setCompoundSecMechArray(int i, org.apache.geronimo.corba.xbeans.csiv2.tss.TSSCompoundSecMechType compoundSecMech)
552            {
553                synchronized (monitor())
554                {
555                    check_orphaned();
556                    org.apache.geronimo.corba.xbeans.csiv2.tss.TSSCompoundSecMechType target = null;
557                    target = (org.apache.geronimo.corba.xbeans.csiv2.tss.TSSCompoundSecMechType)get_store().find_element_user(COMPOUNDSECMECH$0, i);
558                    if (target == null)
559                    {
560                        throw new IndexOutOfBoundsException();
561                    }
562                    target.set(compoundSecMech);
563                }
564            }
565            
566            /**
567             * Inserts and returns a new empty value (as xml) as the ith "compoundSecMech" element
568             */
569            public org.apache.geronimo.corba.xbeans.csiv2.tss.TSSCompoundSecMechType insertNewCompoundSecMech(int i)
570            {
571                synchronized (monitor())
572                {
573                    check_orphaned();
574                    org.apache.geronimo.corba.xbeans.csiv2.tss.TSSCompoundSecMechType target = null;
575                    target = (org.apache.geronimo.corba.xbeans.csiv2.tss.TSSCompoundSecMechType)get_store().insert_element_user(COMPOUNDSECMECH$0, i);
576                    return target;
577                }
578            }
579            
580            /**
581             * Appends and returns a new empty value (as xml) as the last "compoundSecMech" element
582             */
583            public org.apache.geronimo.corba.xbeans.csiv2.tss.TSSCompoundSecMechType addNewCompoundSecMech()
584            {
585                synchronized (monitor())
586                {
587                    check_orphaned();
588                    org.apache.geronimo.corba.xbeans.csiv2.tss.TSSCompoundSecMechType target = null;
589                    target = (org.apache.geronimo.corba.xbeans.csiv2.tss.TSSCompoundSecMechType)get_store().add_element_user(COMPOUNDSECMECH$0);
590                    return target;
591                }
592            }
593            
594            /**
595             * Removes the ith "compoundSecMech" element
596             */
597            public void removeCompoundSecMech(int i)
598            {
599                synchronized (monitor())
600                {
601                    check_orphaned();
602                    get_store().remove_element(COMPOUNDSECMECH$0, i);
603                }
604            }
605            
606            /**
607             * Gets the "stateful" attribute
608             */
609            public boolean getStateful()
610            {
611                synchronized (monitor())
612                {
613                    check_orphaned();
614                    org.apache.xmlbeans.SimpleValue target = null;
615                    target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(STATEFUL$2);
616                    if (target == null)
617                    {
618                        target = (org.apache.xmlbeans.SimpleValue)get_default_attribute_value(STATEFUL$2);
619                    }
620                    if (target == null)
621                    {
622                        return false;
623                    }
624                    return target.getBooleanValue();
625                }
626            }
627            
628            /**
629             * Gets (as xml) the "stateful" attribute
630             */
631            public org.apache.xmlbeans.XmlBoolean xgetStateful()
632            {
633                synchronized (monitor())
634                {
635                    check_orphaned();
636                    org.apache.xmlbeans.XmlBoolean target = null;
637                    target = (org.apache.xmlbeans.XmlBoolean)get_store().find_attribute_user(STATEFUL$2);
638                    if (target == null)
639                    {
640                        target = (org.apache.xmlbeans.XmlBoolean)get_default_attribute_value(STATEFUL$2);
641                    }
642                    return target;
643                }
644            }
645            
646            /**
647             * True if has "stateful" attribute
648             */
649            public boolean isSetStateful()
650            {
651                synchronized (monitor())
652                {
653                    check_orphaned();
654                    return get_store().find_attribute_user(STATEFUL$2) != null;
655                }
656            }
657            
658            /**
659             * Sets the "stateful" attribute
660             */
661            public void setStateful(boolean stateful)
662            {
663                synchronized (monitor())
664                {
665                    check_orphaned();
666                    org.apache.xmlbeans.SimpleValue target = null;
667                    target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(STATEFUL$2);
668                    if (target == null)
669                    {
670                        target = (org.apache.xmlbeans.SimpleValue)get_store().add_attribute_user(STATEFUL$2);
671                    }
672                    target.setBooleanValue(stateful);
673                }
674            }
675            
676            /**
677             * Sets (as xml) the "stateful" attribute
678             */
679            public void xsetStateful(org.apache.xmlbeans.XmlBoolean stateful)
680            {
681                synchronized (monitor())
682                {
683                    check_orphaned();
684                    org.apache.xmlbeans.XmlBoolean target = null;
685                    target = (org.apache.xmlbeans.XmlBoolean)get_store().find_attribute_user(STATEFUL$2);
686                    if (target == null)
687                    {
688                        target = (org.apache.xmlbeans.XmlBoolean)get_store().add_attribute_user(STATEFUL$2);
689                    }
690                    target.set(stateful);
691                }
692            }
693            
694            /**
695             * Unsets the "stateful" attribute
696             */
697            public void unsetStateful()
698            {
699                synchronized (monitor())
700                {
701                    check_orphaned();
702                    get_store().remove_attribute(STATEFUL$2);
703                }
704            }
705        }
706    }