JAL-2629 update spike branch to latest
[jalview.git] / src / jalview / schemabinding / version2 / JSeq.java
1 /*
2  * This class was automatically generated with 
3  * <a href="http://www.castor.org">Castor 1.1</a>, using an XML
4  * Schema.
5  * $Id$
6  */
7
8 package jalview.schemabinding.version2;
9
10   //---------------------------------/
11  //- Imported classes and packages -/
12 //---------------------------------/
13
14 import org.exolab.castor.xml.Marshaller;
15 import org.exolab.castor.xml.Unmarshaller;
16
17 /**
18  * Class JSeq.
19  * 
20  * @version $Revision$ $Date$
21  */
22 public class JSeq implements java.io.Serializable {
23
24
25       //--------------------------/
26      //- Class/Member Variables -/
27     //--------------------------/
28
29     /**
30      * Field _colour.
31      */
32     private int _colour;
33
34     /**
35      * keeps track of state for field: _colour
36      */
37     private boolean _has_colour;
38
39     /**
40      * Field _start.
41      */
42     private int _start;
43
44     /**
45      * keeps track of state for field: _start
46      */
47     private boolean _has_start;
48
49     /**
50      * Field _end.
51      */
52     private int _end;
53
54     /**
55      * keeps track of state for field: _end
56      */
57     private boolean _has_end;
58
59     /**
60      * Field _id.
61      */
62     private java.lang.String _id;
63
64     /**
65      * Field _hidden.
66      */
67     private boolean _hidden;
68
69     /**
70      * keeps track of state for field: _hidden
71      */
72     private boolean _has_hidden;
73
74     /**
75      * Field _viewreference.
76      */
77     private boolean _viewreference;
78
79     /**
80      * keeps track of state for field: _viewreference
81      */
82     private boolean _has_viewreference;
83
84     /**
85      * Field _featuresList.
86      */
87     private java.util.Vector _featuresList;
88
89     /**
90      * Field _pdbidsList.
91      */
92     private java.util.Vector _pdbidsList;
93
94     /**
95      * Field _hiddenSequencesList.
96      */
97     private java.util.Vector _hiddenSequencesList;
98
99     /**
100      * Reference to a viewer showing RNA structure
101      *  for this sequence. Schema supports one viewer showing
102      * multiple
103      *  annotations for multiple sequences, though currently only
104      * one
105      *  annotation for one sequence (gapped or trimmed) is used
106      *  
107      */
108     private java.util.Vector _rnaViewerList;
109
110     /**
111      * name of the project jar entry that holds the HMM file with
112      * the profile for the sequence
113      */
114     private java.lang.String _hmmerProfile;
115
116
117       //----------------/
118      //- Constructors -/
119     //----------------/
120
121     public JSeq() {
122         super();
123         this._featuresList = new java.util.Vector();
124         this._pdbidsList = new java.util.Vector();
125         this._hiddenSequencesList = new java.util.Vector();
126         this._rnaViewerList = new java.util.Vector();
127     }
128
129
130       //-----------/
131      //- Methods -/
132     //-----------/
133
134     /**
135      * 
136      * 
137      * @param vFeatures
138      * @throws java.lang.IndexOutOfBoundsException if the index
139      * given is outside the bounds of the collection
140      */
141     public void addFeatures(
142             final jalview.schemabinding.version2.Features vFeatures)
143     throws java.lang.IndexOutOfBoundsException {
144         this._featuresList.addElement(vFeatures);
145     }
146
147     /**
148      * 
149      * 
150      * @param index
151      * @param vFeatures
152      * @throws java.lang.IndexOutOfBoundsException if the index
153      * given is outside the bounds of the collection
154      */
155     public void addFeatures(
156             final int index,
157             final jalview.schemabinding.version2.Features vFeatures)
158     throws java.lang.IndexOutOfBoundsException {
159         this._featuresList.add(index, vFeatures);
160     }
161
162     /**
163      * 
164      * 
165      * @param vHiddenSequences
166      * @throws java.lang.IndexOutOfBoundsException if the index
167      * given is outside the bounds of the collection
168      */
169     public void addHiddenSequences(
170             final int vHiddenSequences)
171     throws java.lang.IndexOutOfBoundsException {
172         this._hiddenSequencesList.addElement(new java.lang.Integer(vHiddenSequences));
173     }
174
175     /**
176      * 
177      * 
178      * @param index
179      * @param vHiddenSequences
180      * @throws java.lang.IndexOutOfBoundsException if the index
181      * given is outside the bounds of the collection
182      */
183     public void addHiddenSequences(
184             final int index,
185             final int vHiddenSequences)
186     throws java.lang.IndexOutOfBoundsException {
187         this._hiddenSequencesList.add(index, new java.lang.Integer(vHiddenSequences));
188     }
189
190     /**
191      * 
192      * 
193      * @param vPdbids
194      * @throws java.lang.IndexOutOfBoundsException if the index
195      * given is outside the bounds of the collection
196      */
197     public void addPdbids(
198             final jalview.schemabinding.version2.Pdbids vPdbids)
199     throws java.lang.IndexOutOfBoundsException {
200         this._pdbidsList.addElement(vPdbids);
201     }
202
203     /**
204      * 
205      * 
206      * @param index
207      * @param vPdbids
208      * @throws java.lang.IndexOutOfBoundsException if the index
209      * given is outside the bounds of the collection
210      */
211     public void addPdbids(
212             final int index,
213             final jalview.schemabinding.version2.Pdbids vPdbids)
214     throws java.lang.IndexOutOfBoundsException {
215         this._pdbidsList.add(index, vPdbids);
216     }
217
218     /**
219      * 
220      * 
221      * @param vRnaViewer
222      * @throws java.lang.IndexOutOfBoundsException if the index
223      * given is outside the bounds of the collection
224      */
225     public void addRnaViewer(
226             final jalview.schemabinding.version2.RnaViewer vRnaViewer)
227     throws java.lang.IndexOutOfBoundsException {
228         this._rnaViewerList.addElement(vRnaViewer);
229     }
230
231     /**
232      * 
233      * 
234      * @param index
235      * @param vRnaViewer
236      * @throws java.lang.IndexOutOfBoundsException if the index
237      * given is outside the bounds of the collection
238      */
239     public void addRnaViewer(
240             final int index,
241             final jalview.schemabinding.version2.RnaViewer vRnaViewer)
242     throws java.lang.IndexOutOfBoundsException {
243         this._rnaViewerList.add(index, vRnaViewer);
244     }
245
246     /**
247      */
248     public void deleteColour(
249     ) {
250         this._has_colour= false;
251     }
252
253     /**
254      */
255     public void deleteEnd(
256     ) {
257         this._has_end= false;
258     }
259
260     /**
261      */
262     public void deleteHidden(
263     ) {
264         this._has_hidden= false;
265     }
266
267     /**
268      */
269     public void deleteStart(
270     ) {
271         this._has_start= false;
272     }
273
274     /**
275      */
276     public void deleteViewreference(
277     ) {
278         this._has_viewreference= false;
279     }
280
281     /**
282      * Method enumerateFeatures.
283      * 
284      * @return an Enumeration over all
285      * jalview.schemabinding.version2.Features elements
286      */
287     public java.util.Enumeration enumerateFeatures(
288     ) {
289         return this._featuresList.elements();
290     }
291
292     /**
293      * Method enumerateHiddenSequences.
294      * 
295      * @return an Enumeration over all int elements
296      */
297     public java.util.Enumeration enumerateHiddenSequences(
298     ) {
299         return this._hiddenSequencesList.elements();
300     }
301
302     /**
303      * Method enumeratePdbids.
304      * 
305      * @return an Enumeration over all
306      * jalview.schemabinding.version2.Pdbids elements
307      */
308     public java.util.Enumeration enumeratePdbids(
309     ) {
310         return this._pdbidsList.elements();
311     }
312
313     /**
314      * Method enumerateRnaViewer.
315      * 
316      * @return an Enumeration over all
317      * jalview.schemabinding.version2.RnaViewer elements
318      */
319     public java.util.Enumeration enumerateRnaViewer(
320     ) {
321         return this._rnaViewerList.elements();
322     }
323
324     /**
325      * Returns the value of field 'colour'.
326      * 
327      * @return the value of field 'Colour'.
328      */
329     public int getColour(
330     ) {
331         return this._colour;
332     }
333
334     /**
335      * Returns the value of field 'end'.
336      * 
337      * @return the value of field 'End'.
338      */
339     public int getEnd(
340     ) {
341         return this._end;
342     }
343
344     /**
345      * Method getFeatures.
346      * 
347      * @param index
348      * @throws java.lang.IndexOutOfBoundsException if the index
349      * given is outside the bounds of the collection
350      * @return the value of the
351      * jalview.schemabinding.version2.Features at the given index
352      */
353     public jalview.schemabinding.version2.Features getFeatures(
354             final int index)
355     throws java.lang.IndexOutOfBoundsException {
356         // check bounds for index
357         if (index < 0 || index >= this._featuresList.size()) {
358             throw new IndexOutOfBoundsException("getFeatures: Index value '" + index + "' not in range [0.." + (this._featuresList.size() - 1) + "]");
359         }
360         
361         return (jalview.schemabinding.version2.Features) _featuresList.get(index);
362     }
363
364     /**
365      * Method getFeatures.Returns the contents of the collection in
366      * an Array.  <p>Note:  Just in case the collection contents
367      * are changing in another thread, we pass a 0-length Array of
368      * the correct type into the API call.  This way we <i>know</i>
369      * that the Array returned is of exactly the correct length.
370      * 
371      * @return this collection as an Array
372      */
373     public jalview.schemabinding.version2.Features[] getFeatures(
374     ) {
375         jalview.schemabinding.version2.Features[] array = new jalview.schemabinding.version2.Features[0];
376         return (jalview.schemabinding.version2.Features[]) this._featuresList.toArray(array);
377     }
378
379     /**
380      * Method getFeaturesCount.
381      * 
382      * @return the size of this collection
383      */
384     public int getFeaturesCount(
385     ) {
386         return this._featuresList.size();
387     }
388
389     /**
390      * Returns the value of field 'hidden'.
391      * 
392      * @return the value of field 'Hidden'.
393      */
394     public boolean getHidden(
395     ) {
396         return this._hidden;
397     }
398
399     /**
400      * Method getHiddenSequences.
401      * 
402      * @param index
403      * @throws java.lang.IndexOutOfBoundsException if the index
404      * given is outside the bounds of the collection
405      * @return the value of the int at the given index
406      */
407     public int getHiddenSequences(
408             final int index)
409     throws java.lang.IndexOutOfBoundsException {
410         // check bounds for index
411         if (index < 0 || index >= this._hiddenSequencesList.size()) {
412             throw new IndexOutOfBoundsException("getHiddenSequences: Index value '" + index + "' not in range [0.." + (this._hiddenSequencesList.size() - 1) + "]");
413         }
414         
415         return ((java.lang.Integer) _hiddenSequencesList.get(index)).intValue();
416     }
417
418     /**
419      * Method getHiddenSequences.Returns the contents of the
420      * collection in an Array.  
421      * 
422      * @return this collection as an Array
423      */
424     public int[] getHiddenSequences(
425     ) {
426         int size = this._hiddenSequencesList.size();
427         int[] array = new int[size];
428         java.util.Iterator iter = _hiddenSequencesList.iterator();
429         for (int index = 0; index < size; index++) {
430             array[index] = ((java.lang.Integer) iter.next()).intValue();
431         }
432         return array;
433     }
434
435     /**
436      * Method getHiddenSequencesCount.
437      * 
438      * @return the size of this collection
439      */
440     public int getHiddenSequencesCount(
441     ) {
442         return this._hiddenSequencesList.size();
443     }
444
445     /**
446      * Returns the value of field 'hmmerProfile'. The field
447      * 'hmmerProfile' has the following description: name of the
448      * project jar entry that holds the HMM file with the profile
449      * for the sequence
450      * 
451      * @return the value of field 'HmmerProfile'.
452      */
453     public java.lang.String getHmmerProfile(
454     ) {
455         return this._hmmerProfile;
456     }
457
458     /**
459      * Returns the value of field 'id'.
460      * 
461      * @return the value of field 'Id'.
462      */
463     public java.lang.String getId(
464     ) {
465         return this._id;
466     }
467
468     /**
469      * Method getPdbids.
470      * 
471      * @param index
472      * @throws java.lang.IndexOutOfBoundsException if the index
473      * given is outside the bounds of the collection
474      * @return the value of the
475      * jalview.schemabinding.version2.Pdbids at the given index
476      */
477     public jalview.schemabinding.version2.Pdbids getPdbids(
478             final int index)
479     throws java.lang.IndexOutOfBoundsException {
480         // check bounds for index
481         if (index < 0 || index >= this._pdbidsList.size()) {
482             throw new IndexOutOfBoundsException("getPdbids: Index value '" + index + "' not in range [0.." + (this._pdbidsList.size() - 1) + "]");
483         }
484         
485         return (jalview.schemabinding.version2.Pdbids) _pdbidsList.get(index);
486     }
487
488     /**
489      * Method getPdbids.Returns the contents of the collection in
490      * an Array.  <p>Note:  Just in case the collection contents
491      * are changing in another thread, we pass a 0-length Array of
492      * the correct type into the API call.  This way we <i>know</i>
493      * that the Array returned is of exactly the correct length.
494      * 
495      * @return this collection as an Array
496      */
497     public jalview.schemabinding.version2.Pdbids[] getPdbids(
498     ) {
499         jalview.schemabinding.version2.Pdbids[] array = new jalview.schemabinding.version2.Pdbids[0];
500         return (jalview.schemabinding.version2.Pdbids[]) this._pdbidsList.toArray(array);
501     }
502
503     /**
504      * Method getPdbidsCount.
505      * 
506      * @return the size of this collection
507      */
508     public int getPdbidsCount(
509     ) {
510         return this._pdbidsList.size();
511     }
512
513     /**
514      * Method getRnaViewer.
515      * 
516      * @param index
517      * @throws java.lang.IndexOutOfBoundsException if the index
518      * given is outside the bounds of the collection
519      * @return the value of the
520      * jalview.schemabinding.version2.RnaViewer at the given index
521      */
522     public jalview.schemabinding.version2.RnaViewer getRnaViewer(
523             final int index)
524     throws java.lang.IndexOutOfBoundsException {
525         // check bounds for index
526         if (index < 0 || index >= this._rnaViewerList.size()) {
527             throw new IndexOutOfBoundsException("getRnaViewer: Index value '" + index + "' not in range [0.." + (this._rnaViewerList.size() - 1) + "]");
528         }
529         
530         return (jalview.schemabinding.version2.RnaViewer) _rnaViewerList.get(index);
531     }
532
533     /**
534      * Method getRnaViewer.Returns the contents of the collection
535      * in an Array.  <p>Note:  Just in case the collection contents
536      * are changing in another thread, we pass a 0-length Array of
537      * the correct type into the API call.  This way we <i>know</i>
538      * that the Array returned is of exactly the correct length.
539      * 
540      * @return this collection as an Array
541      */
542     public jalview.schemabinding.version2.RnaViewer[] getRnaViewer(
543     ) {
544         jalview.schemabinding.version2.RnaViewer[] array = new jalview.schemabinding.version2.RnaViewer[0];
545         return (jalview.schemabinding.version2.RnaViewer[]) this._rnaViewerList.toArray(array);
546     }
547
548     /**
549      * Method getRnaViewerCount.
550      * 
551      * @return the size of this collection
552      */
553     public int getRnaViewerCount(
554     ) {
555         return this._rnaViewerList.size();
556     }
557
558     /**
559      * Returns the value of field 'start'.
560      * 
561      * @return the value of field 'Start'.
562      */
563     public int getStart(
564     ) {
565         return this._start;
566     }
567
568     /**
569      * Returns the value of field 'viewreference'.
570      * 
571      * @return the value of field 'Viewreference'.
572      */
573     public boolean getViewreference(
574     ) {
575         return this._viewreference;
576     }
577
578     /**
579      * Method hasColour.
580      * 
581      * @return true if at least one Colour has been added
582      */
583     public boolean hasColour(
584     ) {
585         return this._has_colour;
586     }
587
588     /**
589      * Method hasEnd.
590      * 
591      * @return true if at least one End has been added
592      */
593     public boolean hasEnd(
594     ) {
595         return this._has_end;
596     }
597
598     /**
599      * Method hasHidden.
600      * 
601      * @return true if at least one Hidden has been added
602      */
603     public boolean hasHidden(
604     ) {
605         return this._has_hidden;
606     }
607
608     /**
609      * Method hasStart.
610      * 
611      * @return true if at least one Start has been added
612      */
613     public boolean hasStart(
614     ) {
615         return this._has_start;
616     }
617
618     /**
619      * Method hasViewreference.
620      * 
621      * @return true if at least one Viewreference has been added
622      */
623     public boolean hasViewreference(
624     ) {
625         return this._has_viewreference;
626     }
627
628     /**
629      * Returns the value of field 'hidden'.
630      * 
631      * @return the value of field 'Hidden'.
632      */
633     public boolean isHidden(
634     ) {
635         return this._hidden;
636     }
637
638     /**
639      * Method isValid.
640      * 
641      * @return true if this object is valid according to the schema
642      */
643     public boolean isValid(
644     ) {
645         try {
646             validate();
647         } catch (org.exolab.castor.xml.ValidationException vex) {
648             return false;
649         }
650         return true;
651     }
652
653     /**
654      * Returns the value of field 'viewreference'.
655      * 
656      * @return the value of field 'Viewreference'.
657      */
658     public boolean isViewreference(
659     ) {
660         return this._viewreference;
661     }
662
663     /**
664      * 
665      * 
666      * @param out
667      * @throws org.exolab.castor.xml.MarshalException if object is
668      * null or if any SAXException is thrown during marshaling
669      * @throws org.exolab.castor.xml.ValidationException if this
670      * object is an invalid instance according to the schema
671      */
672     public void marshal(
673             final java.io.Writer out)
674     throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {
675         Marshaller.marshal(this, out);
676     }
677
678     /**
679      * 
680      * 
681      * @param handler
682      * @throws java.io.IOException if an IOException occurs during
683      * marshaling
684      * @throws org.exolab.castor.xml.ValidationException if this
685      * object is an invalid instance according to the schema
686      * @throws org.exolab.castor.xml.MarshalException if object is
687      * null or if any SAXException is thrown during marshaling
688      */
689     public void marshal(
690             final org.xml.sax.ContentHandler handler)
691     throws java.io.IOException, org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {
692         Marshaller.marshal(this, handler);
693     }
694
695     /**
696      */
697     public void removeAllFeatures(
698     ) {
699         this._featuresList.clear();
700     }
701
702     /**
703      */
704     public void removeAllHiddenSequences(
705     ) {
706         this._hiddenSequencesList.clear();
707     }
708
709     /**
710      */
711     public void removeAllPdbids(
712     ) {
713         this._pdbidsList.clear();
714     }
715
716     /**
717      */
718     public void removeAllRnaViewer(
719     ) {
720         this._rnaViewerList.clear();
721     }
722
723     /**
724      * Method removeFeatures.
725      * 
726      * @param vFeatures
727      * @return true if the object was removed from the collection.
728      */
729     public boolean removeFeatures(
730             final jalview.schemabinding.version2.Features vFeatures) {
731         boolean removed = _featuresList.remove(vFeatures);
732         return removed;
733     }
734
735     /**
736      * Method removeFeaturesAt.
737      * 
738      * @param index
739      * @return the element removed from the collection
740      */
741     public jalview.schemabinding.version2.Features removeFeaturesAt(
742             final int index) {
743         java.lang.Object obj = this._featuresList.remove(index);
744         return (jalview.schemabinding.version2.Features) obj;
745     }
746
747     /**
748      * Method removeHiddenSequences.
749      * 
750      * @param vHiddenSequences
751      * @return true if the object was removed from the collection.
752      */
753     public boolean removeHiddenSequences(
754             final int vHiddenSequences) {
755         boolean removed = _hiddenSequencesList.remove(new java.lang.Integer(vHiddenSequences));
756         return removed;
757     }
758
759     /**
760      * Method removeHiddenSequencesAt.
761      * 
762      * @param index
763      * @return the element removed from the collection
764      */
765     public int removeHiddenSequencesAt(
766             final int index) {
767         java.lang.Object obj = this._hiddenSequencesList.remove(index);
768         return ((java.lang.Integer) obj).intValue();
769     }
770
771     /**
772      * Method removePdbids.
773      * 
774      * @param vPdbids
775      * @return true if the object was removed from the collection.
776      */
777     public boolean removePdbids(
778             final jalview.schemabinding.version2.Pdbids vPdbids) {
779         boolean removed = _pdbidsList.remove(vPdbids);
780         return removed;
781     }
782
783     /**
784      * Method removePdbidsAt.
785      * 
786      * @param index
787      * @return the element removed from the collection
788      */
789     public jalview.schemabinding.version2.Pdbids removePdbidsAt(
790             final int index) {
791         java.lang.Object obj = this._pdbidsList.remove(index);
792         return (jalview.schemabinding.version2.Pdbids) obj;
793     }
794
795     /**
796      * Method removeRnaViewer.
797      * 
798      * @param vRnaViewer
799      * @return true if the object was removed from the collection.
800      */
801     public boolean removeRnaViewer(
802             final jalview.schemabinding.version2.RnaViewer vRnaViewer) {
803         boolean removed = _rnaViewerList.remove(vRnaViewer);
804         return removed;
805     }
806
807     /**
808      * Method removeRnaViewerAt.
809      * 
810      * @param index
811      * @return the element removed from the collection
812      */
813     public jalview.schemabinding.version2.RnaViewer removeRnaViewerAt(
814             final int index) {
815         java.lang.Object obj = this._rnaViewerList.remove(index);
816         return (jalview.schemabinding.version2.RnaViewer) obj;
817     }
818
819     /**
820      * Sets the value of field 'colour'.
821      * 
822      * @param colour the value of field 'colour'.
823      */
824     public void setColour(
825             final int colour) {
826         this._colour = colour;
827         this._has_colour = true;
828     }
829
830     /**
831      * Sets the value of field 'end'.
832      * 
833      * @param end the value of field 'end'.
834      */
835     public void setEnd(
836             final int end) {
837         this._end = end;
838         this._has_end = true;
839     }
840
841     /**
842      * 
843      * 
844      * @param index
845      * @param vFeatures
846      * @throws java.lang.IndexOutOfBoundsException if the index
847      * given is outside the bounds of the collection
848      */
849     public void setFeatures(
850             final int index,
851             final jalview.schemabinding.version2.Features vFeatures)
852     throws java.lang.IndexOutOfBoundsException {
853         // check bounds for index
854         if (index < 0 || index >= this._featuresList.size()) {
855             throw new IndexOutOfBoundsException("setFeatures: Index value '" + index + "' not in range [0.." + (this._featuresList.size() - 1) + "]");
856         }
857         
858         this._featuresList.set(index, vFeatures);
859     }
860
861     /**
862      * 
863      * 
864      * @param vFeaturesArray
865      */
866     public void setFeatures(
867             final jalview.schemabinding.version2.Features[] vFeaturesArray) {
868         //-- copy array
869         _featuresList.clear();
870         
871         for (int i = 0; i < vFeaturesArray.length; i++) {
872                 this._featuresList.add(vFeaturesArray[i]);
873         }
874     }
875
876     /**
877      * Sets the value of field 'hidden'.
878      * 
879      * @param hidden the value of field 'hidden'.
880      */
881     public void setHidden(
882             final boolean hidden) {
883         this._hidden = hidden;
884         this._has_hidden = true;
885     }
886
887     /**
888      * 
889      * 
890      * @param index
891      * @param vHiddenSequences
892      * @throws java.lang.IndexOutOfBoundsException if the index
893      * given is outside the bounds of the collection
894      */
895     public void setHiddenSequences(
896             final int index,
897             final int vHiddenSequences)
898     throws java.lang.IndexOutOfBoundsException {
899         // check bounds for index
900         if (index < 0 || index >= this._hiddenSequencesList.size()) {
901             throw new IndexOutOfBoundsException("setHiddenSequences: Index value '" + index + "' not in range [0.." + (this._hiddenSequencesList.size() - 1) + "]");
902         }
903         
904         this._hiddenSequencesList.set(index, new java.lang.Integer(vHiddenSequences));
905     }
906
907     /**
908      * 
909      * 
910      * @param vHiddenSequencesArray
911      */
912     public void setHiddenSequences(
913             final int[] vHiddenSequencesArray) {
914         //-- copy array
915         _hiddenSequencesList.clear();
916         
917         for (int i = 0; i < vHiddenSequencesArray.length; i++) {
918                 this._hiddenSequencesList.add(new java.lang.Integer(vHiddenSequencesArray[i]));
919         }
920     }
921
922     /**
923      * Sets the value of field 'hmmerProfile'. The field
924      * 'hmmerProfile' has the following description: name of the
925      * project jar entry that holds the HMM file with the profile
926      * for the sequence
927      * 
928      * @param hmmerProfile the value of field 'hmmerProfile'.
929      */
930     public void setHmmerProfile(
931             final java.lang.String hmmerProfile) {
932         this._hmmerProfile = hmmerProfile;
933     }
934
935     /**
936      * Sets the value of field 'id'.
937      * 
938      * @param id the value of field 'id'.
939      */
940     public void setId(
941             final java.lang.String id) {
942         this._id = id;
943     }
944
945     /**
946      * 
947      * 
948      * @param index
949      * @param vPdbids
950      * @throws java.lang.IndexOutOfBoundsException if the index
951      * given is outside the bounds of the collection
952      */
953     public void setPdbids(
954             final int index,
955             final jalview.schemabinding.version2.Pdbids vPdbids)
956     throws java.lang.IndexOutOfBoundsException {
957         // check bounds for index
958         if (index < 0 || index >= this._pdbidsList.size()) {
959             throw new IndexOutOfBoundsException("setPdbids: Index value '" + index + "' not in range [0.." + (this._pdbidsList.size() - 1) + "]");
960         }
961         
962         this._pdbidsList.set(index, vPdbids);
963     }
964
965     /**
966      * 
967      * 
968      * @param vPdbidsArray
969      */
970     public void setPdbids(
971             final jalview.schemabinding.version2.Pdbids[] vPdbidsArray) {
972         //-- copy array
973         _pdbidsList.clear();
974         
975         for (int i = 0; i < vPdbidsArray.length; i++) {
976                 this._pdbidsList.add(vPdbidsArray[i]);
977         }
978     }
979
980     /**
981      * 
982      * 
983      * @param index
984      * @param vRnaViewer
985      * @throws java.lang.IndexOutOfBoundsException if the index
986      * given is outside the bounds of the collection
987      */
988     public void setRnaViewer(
989             final int index,
990             final jalview.schemabinding.version2.RnaViewer vRnaViewer)
991     throws java.lang.IndexOutOfBoundsException {
992         // check bounds for index
993         if (index < 0 || index >= this._rnaViewerList.size()) {
994             throw new IndexOutOfBoundsException("setRnaViewer: Index value '" + index + "' not in range [0.." + (this._rnaViewerList.size() - 1) + "]");
995         }
996         
997         this._rnaViewerList.set(index, vRnaViewer);
998     }
999
1000     /**
1001      * 
1002      * 
1003      * @param vRnaViewerArray
1004      */
1005     public void setRnaViewer(
1006             final jalview.schemabinding.version2.RnaViewer[] vRnaViewerArray) {
1007         //-- copy array
1008         _rnaViewerList.clear();
1009         
1010         for (int i = 0; i < vRnaViewerArray.length; i++) {
1011                 this._rnaViewerList.add(vRnaViewerArray[i]);
1012         }
1013     }
1014
1015     /**
1016      * Sets the value of field 'start'.
1017      * 
1018      * @param start the value of field 'start'.
1019      */
1020     public void setStart(
1021             final int start) {
1022         this._start = start;
1023         this._has_start = true;
1024     }
1025
1026     /**
1027      * Sets the value of field 'viewreference'.
1028      * 
1029      * @param viewreference the value of field 'viewreference'.
1030      */
1031     public void setViewreference(
1032             final boolean viewreference) {
1033         this._viewreference = viewreference;
1034         this._has_viewreference = true;
1035     }
1036
1037     /**
1038      * Method unmarshal.
1039      * 
1040      * @param reader
1041      * @throws org.exolab.castor.xml.MarshalException if object is
1042      * null or if any SAXException is thrown during marshaling
1043      * @throws org.exolab.castor.xml.ValidationException if this
1044      * object is an invalid instance according to the schema
1045      * @return the unmarshaled jalview.schemabinding.version2.JSeq
1046      */
1047     public static jalview.schemabinding.version2.JSeq unmarshal(
1048             final java.io.Reader reader)
1049     throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {
1050         return (jalview.schemabinding.version2.JSeq) Unmarshaller.unmarshal(jalview.schemabinding.version2.JSeq.class, reader);
1051     }
1052
1053     /**
1054      * 
1055      * 
1056      * @throws org.exolab.castor.xml.ValidationException if this
1057      * object is an invalid instance according to the schema
1058      */
1059     public void validate(
1060     )
1061     throws org.exolab.castor.xml.ValidationException {
1062         org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
1063         validator.validate(this);
1064     }
1065
1066 }