JAL-1517 fix copyright for 2.8.2
[jalview.git] / src / jalview / schemabinding / version2 / JGroup.java
1 /*
2  * Jalview - A Sequence Alignment Editor and Viewer (Version 2.8.2)
3  * Copyright (C) 2014 The Jalview Authors
4  * 
5  * This file is part of Jalview.
6  * 
7  * Jalview is free software: you can redistribute it and/or
8  * modify it under the terms of the GNU General Public License 
9  * as published by the Free Software Foundation, either version 3
10  * of the License, or (at your option) any later version.
11  *  
12  * Jalview is distributed in the hope that it will be useful, but 
13  * WITHOUT ANY WARRANTY; without even the implied warranty 
14  * of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
15  * PURPOSE.  See the GNU General Public License for more details.
16  * 
17  * You should have received a copy of the GNU General Public License
18  * along with Jalview.  If not, see <http://www.gnu.org/licenses/>.
19  * The Jalview Authors are detailed in the 'AUTHORS' file.
20  */
21 package jalview.schemabinding.version2;
22
23 //---------------------------------/
24 //- Imported classes and packages -/
25 //---------------------------------/
26
27 import org.exolab.castor.xml.Marshaller;
28 import org.exolab.castor.xml.Unmarshaller;
29
30 /**
31  * Class JGroup.
32  * 
33  * @version $Revision$ $Date$
34  */
35 public class JGroup implements java.io.Serializable
36 {
37
38   // --------------------------/
39   // - Class/Member Variables -/
40   // --------------------------/
41
42   /**
43    * Field _start.
44    */
45   private int _start;
46
47   /**
48    * keeps track of state for field: _start
49    */
50   private boolean _has_start;
51
52   /**
53    * Field _end.
54    */
55   private int _end;
56
57   /**
58    * keeps track of state for field: _end
59    */
60   private boolean _has_end;
61
62   /**
63    * Field _name.
64    */
65   private java.lang.String _name;
66
67   /**
68    * Field _colour.
69    */
70   private java.lang.String _colour;
71
72   /**
73    * Field _consThreshold.
74    */
75   private int _consThreshold;
76
77   /**
78    * keeps track of state for field: _consThreshold
79    */
80   private boolean _has_consThreshold;
81
82   /**
83    * Field _pidThreshold.
84    */
85   private int _pidThreshold;
86
87   /**
88    * keeps track of state for field: _pidThreshold
89    */
90   private boolean _has_pidThreshold;
91
92   /**
93    * Field _outlineColour.
94    */
95   private int _outlineColour;
96
97   /**
98    * keeps track of state for field: _outlineColour
99    */
100   private boolean _has_outlineColour;
101
102   /**
103    * Field _displayBoxes.
104    */
105   private boolean _displayBoxes;
106
107   /**
108    * keeps track of state for field: _displayBoxes
109    */
110   private boolean _has_displayBoxes;
111
112   /**
113    * Field _displayText.
114    */
115   private boolean _displayText;
116
117   /**
118    * keeps track of state for field: _displayText
119    */
120   private boolean _has_displayText;
121
122   /**
123    * Field _colourText.
124    */
125   private boolean _colourText;
126
127   /**
128    * keeps track of state for field: _colourText
129    */
130   private boolean _has_colourText;
131
132   /**
133    * Field _textCol1.
134    */
135   private int _textCol1;
136
137   /**
138    * keeps track of state for field: _textCol1
139    */
140   private boolean _has_textCol1;
141
142   /**
143    * Field _textCol2.
144    */
145   private int _textCol2;
146
147   /**
148    * keeps track of state for field: _textCol2
149    */
150   private boolean _has_textCol2;
151
152   /**
153    * Field _textColThreshold.
154    */
155   private int _textColThreshold;
156
157   /**
158    * keeps track of state for field: _textColThreshold
159    */
160   private boolean _has_textColThreshold;
161
162   /**
163    * Field _showUnconserved.
164    */
165   private boolean _showUnconserved;
166
167   /**
168    * keeps track of state for field: _showUnconserved
169    */
170   private boolean _has_showUnconserved;
171
172   /**
173    * Field _ignoreGapsinConsensus.
174    */
175   private boolean _ignoreGapsinConsensus = true;
176
177   /**
178    * keeps track of state for field: _ignoreGapsinConsensus
179    */
180   private boolean _has_ignoreGapsinConsensus;
181
182   /**
183    * Field _showConsensusHistogram.
184    */
185   private boolean _showConsensusHistogram = true;
186
187   /**
188    * keeps track of state for field: _showConsensusHistogram
189    */
190   private boolean _has_showConsensusHistogram;
191
192   /**
193    * Field _showSequenceLogo.
194    */
195   private boolean _showSequenceLogo = false;
196
197   /**
198    * keeps track of state for field: _showSequenceLogo
199    */
200   private boolean _has_showSequenceLogo;
201
202   /**
203    * Field _normaliseSequenceLogo.
204    */
205   private boolean _normaliseSequenceLogo = false;
206
207   /**
208    * keeps track of state for field: _normaliseSequenceLogo
209    */
210   private boolean _has_normaliseSequenceLogo;
211
212   /**
213    * Optional sequence group ID (only needs to be unique for this alignment)
214    * 
215    */
216   private java.lang.String _id;
217
218   /**
219    * Field _seqList.
220    */
221   private java.util.Vector _seqList;
222
223   /**
224    * Field _annotationColours.
225    */
226   private jalview.schemabinding.version2.AnnotationColours _annotationColours;
227
228   // ----------------/
229   // - Constructors -/
230   // ----------------/
231
232   public JGroup()
233   {
234     super();
235     this._seqList = new java.util.Vector();
236   }
237
238   // -----------/
239   // - Methods -/
240   // -----------/
241
242   /**
243    * 
244    * 
245    * @param vSeq
246    * @throws java.lang.IndexOutOfBoundsException
247    *           if the index given is outside the bounds of the collection
248    */
249   public void addSeq(final java.lang.String vSeq)
250           throws java.lang.IndexOutOfBoundsException
251   {
252     this._seqList.addElement(vSeq);
253   }
254
255   /**
256    * 
257    * 
258    * @param index
259    * @param vSeq
260    * @throws java.lang.IndexOutOfBoundsException
261    *           if the index given is outside the bounds of the collection
262    */
263   public void addSeq(final int index, final java.lang.String vSeq)
264           throws java.lang.IndexOutOfBoundsException
265   {
266     this._seqList.add(index, vSeq);
267   }
268
269   /**
270      */
271   public void deleteColourText()
272   {
273     this._has_colourText = false;
274   }
275
276   /**
277      */
278   public void deleteConsThreshold()
279   {
280     this._has_consThreshold = false;
281   }
282
283   /**
284      */
285   public void deleteDisplayBoxes()
286   {
287     this._has_displayBoxes = false;
288   }
289
290   /**
291      */
292   public void deleteDisplayText()
293   {
294     this._has_displayText = false;
295   }
296
297   /**
298      */
299   public void deleteEnd()
300   {
301     this._has_end = false;
302   }
303
304   /**
305      */
306   public void deleteIgnoreGapsinConsensus()
307   {
308     this._has_ignoreGapsinConsensus = false;
309   }
310
311   /**
312      */
313   public void deleteNormaliseSequenceLogo()
314   {
315     this._has_normaliseSequenceLogo = false;
316   }
317
318   /**
319      */
320   public void deleteOutlineColour()
321   {
322     this._has_outlineColour = false;
323   }
324
325   /**
326      */
327   public void deletePidThreshold()
328   {
329     this._has_pidThreshold = false;
330   }
331
332   /**
333      */
334   public void deleteShowConsensusHistogram()
335   {
336     this._has_showConsensusHistogram = false;
337   }
338
339   /**
340      */
341   public void deleteShowSequenceLogo()
342   {
343     this._has_showSequenceLogo = false;
344   }
345
346   /**
347      */
348   public void deleteShowUnconserved()
349   {
350     this._has_showUnconserved = false;
351   }
352
353   /**
354      */
355   public void deleteStart()
356   {
357     this._has_start = false;
358   }
359
360   /**
361      */
362   public void deleteTextCol1()
363   {
364     this._has_textCol1 = false;
365   }
366
367   /**
368      */
369   public void deleteTextCol2()
370   {
371     this._has_textCol2 = false;
372   }
373
374   /**
375      */
376   public void deleteTextColThreshold()
377   {
378     this._has_textColThreshold = false;
379   }
380
381   /**
382    * Method enumerateSeq.
383    * 
384    * @return an Enumeration over all java.lang.String elements
385    */
386   public java.util.Enumeration enumerateSeq()
387   {
388     return this._seqList.elements();
389   }
390
391   /**
392    * Returns the value of field 'annotationColours'.
393    * 
394    * @return the value of field 'AnnotationColours'.
395    */
396   public jalview.schemabinding.version2.AnnotationColours getAnnotationColours()
397   {
398     return this._annotationColours;
399   }
400
401   /**
402    * Returns the value of field 'colour'.
403    * 
404    * @return the value of field 'Colour'.
405    */
406   public java.lang.String getColour()
407   {
408     return this._colour;
409   }
410
411   /**
412    * Returns the value of field 'colourText'.
413    * 
414    * @return the value of field 'ColourText'.
415    */
416   public boolean getColourText()
417   {
418     return this._colourText;
419   }
420
421   /**
422    * Returns the value of field 'consThreshold'.
423    * 
424    * @return the value of field 'ConsThreshold'.
425    */
426   public int getConsThreshold()
427   {
428     return this._consThreshold;
429   }
430
431   /**
432    * Returns the value of field 'displayBoxes'.
433    * 
434    * @return the value of field 'DisplayBoxes'.
435    */
436   public boolean getDisplayBoxes()
437   {
438     return this._displayBoxes;
439   }
440
441   /**
442    * Returns the value of field 'displayText'.
443    * 
444    * @return the value of field 'DisplayText'.
445    */
446   public boolean getDisplayText()
447   {
448     return this._displayText;
449   }
450
451   /**
452    * Returns the value of field 'end'.
453    * 
454    * @return the value of field 'End'.
455    */
456   public int getEnd()
457   {
458     return this._end;
459   }
460
461   /**
462    * Returns the value of field 'id'. The field 'id' has the following
463    * description: Optional sequence group ID (only needs to be unique for this
464    * alignment)
465    * 
466    * 
467    * @return the value of field 'Id'.
468    */
469   public java.lang.String getId()
470   {
471     return this._id;
472   }
473
474   /**
475    * Returns the value of field 'ignoreGapsinConsensus'.
476    * 
477    * @return the value of field 'IgnoreGapsinConsensus'.
478    */
479   public boolean getIgnoreGapsinConsensus()
480   {
481     return this._ignoreGapsinConsensus;
482   }
483
484   /**
485    * Returns the value of field 'name'.
486    * 
487    * @return the value of field 'Name'.
488    */
489   public java.lang.String getName()
490   {
491     return this._name;
492   }
493
494   /**
495    * Returns the value of field 'normaliseSequenceLogo'.
496    * 
497    * @return the value of field 'NormaliseSequenceLogo'.
498    */
499   public boolean getNormaliseSequenceLogo()
500   {
501     return this._normaliseSequenceLogo;
502   }
503
504   /**
505    * Returns the value of field 'outlineColour'.
506    * 
507    * @return the value of field 'OutlineColour'.
508    */
509   public int getOutlineColour()
510   {
511     return this._outlineColour;
512   }
513
514   /**
515    * Returns the value of field 'pidThreshold'.
516    * 
517    * @return the value of field 'PidThreshold'.
518    */
519   public int getPidThreshold()
520   {
521     return this._pidThreshold;
522   }
523
524   /**
525    * Method getSeq.
526    * 
527    * @param index
528    * @throws java.lang.IndexOutOfBoundsException
529    *           if the index given is outside the bounds of the collection
530    * @return the value of the java.lang.String at the given index
531    */
532   public java.lang.String getSeq(final int index)
533           throws java.lang.IndexOutOfBoundsException
534   {
535     // check bounds for index
536     if (index < 0 || index >= this._seqList.size())
537     {
538       throw new IndexOutOfBoundsException("getSeq: Index value '" + index
539               + "' not in range [0.." + (this._seqList.size() - 1) + "]");
540     }
541
542     return (java.lang.String) _seqList.get(index);
543   }
544
545   /**
546    * Method getSeq.Returns the contents of the collection in an Array.
547    * <p>
548    * Note: Just in case the collection contents are changing in another thread,
549    * we pass a 0-length Array of the correct type into the API call. This way we
550    * <i>know</i> that the Array returned is of exactly the correct length.
551    * 
552    * @return this collection as an Array
553    */
554   public java.lang.String[] getSeq()
555   {
556     java.lang.String[] array = new java.lang.String[0];
557     return (java.lang.String[]) this._seqList.toArray(array);
558   }
559
560   /**
561    * Method getSeqCount.
562    * 
563    * @return the size of this collection
564    */
565   public int getSeqCount()
566   {
567     return this._seqList.size();
568   }
569
570   /**
571    * Returns the value of field 'showConsensusHistogram'.
572    * 
573    * @return the value of field 'ShowConsensusHistogram'.
574    */
575   public boolean getShowConsensusHistogram()
576   {
577     return this._showConsensusHistogram;
578   }
579
580   /**
581    * Returns the value of field 'showSequenceLogo'.
582    * 
583    * @return the value of field 'ShowSequenceLogo'.
584    */
585   public boolean getShowSequenceLogo()
586   {
587     return this._showSequenceLogo;
588   }
589
590   /**
591    * Returns the value of field 'showUnconserved'.
592    * 
593    * @return the value of field 'ShowUnconserved'.
594    */
595   public boolean getShowUnconserved()
596   {
597     return this._showUnconserved;
598   }
599
600   /**
601    * Returns the value of field 'start'.
602    * 
603    * @return the value of field 'Start'.
604    */
605   public int getStart()
606   {
607     return this._start;
608   }
609
610   /**
611    * Returns the value of field 'textCol1'.
612    * 
613    * @return the value of field 'TextCol1'.
614    */
615   public int getTextCol1()
616   {
617     return this._textCol1;
618   }
619
620   /**
621    * Returns the value of field 'textCol2'.
622    * 
623    * @return the value of field 'TextCol2'.
624    */
625   public int getTextCol2()
626   {
627     return this._textCol2;
628   }
629
630   /**
631    * Returns the value of field 'textColThreshold'.
632    * 
633    * @return the value of field 'TextColThreshold'.
634    */
635   public int getTextColThreshold()
636   {
637     return this._textColThreshold;
638   }
639
640   /**
641    * Method hasColourText.
642    * 
643    * @return true if at least one ColourText has been added
644    */
645   public boolean hasColourText()
646   {
647     return this._has_colourText;
648   }
649
650   /**
651    * Method hasConsThreshold.
652    * 
653    * @return true if at least one ConsThreshold has been added
654    */
655   public boolean hasConsThreshold()
656   {
657     return this._has_consThreshold;
658   }
659
660   /**
661    * Method hasDisplayBoxes.
662    * 
663    * @return true if at least one DisplayBoxes has been added
664    */
665   public boolean hasDisplayBoxes()
666   {
667     return this._has_displayBoxes;
668   }
669
670   /**
671    * Method hasDisplayText.
672    * 
673    * @return true if at least one DisplayText has been added
674    */
675   public boolean hasDisplayText()
676   {
677     return this._has_displayText;
678   }
679
680   /**
681    * Method hasEnd.
682    * 
683    * @return true if at least one End has been added
684    */
685   public boolean hasEnd()
686   {
687     return this._has_end;
688   }
689
690   /**
691    * Method hasIgnoreGapsinConsensus.
692    * 
693    * @return true if at least one IgnoreGapsinConsensus has been added
694    */
695   public boolean hasIgnoreGapsinConsensus()
696   {
697     return this._has_ignoreGapsinConsensus;
698   }
699
700   /**
701    * Method hasNormaliseSequenceLogo.
702    * 
703    * @return true if at least one NormaliseSequenceLogo has been added
704    */
705   public boolean hasNormaliseSequenceLogo()
706   {
707     return this._has_normaliseSequenceLogo;
708   }
709
710   /**
711    * Method hasOutlineColour.
712    * 
713    * @return true if at least one OutlineColour has been added
714    */
715   public boolean hasOutlineColour()
716   {
717     return this._has_outlineColour;
718   }
719
720   /**
721    * Method hasPidThreshold.
722    * 
723    * @return true if at least one PidThreshold has been added
724    */
725   public boolean hasPidThreshold()
726   {
727     return this._has_pidThreshold;
728   }
729
730   /**
731    * Method hasShowConsensusHistogram.
732    * 
733    * @return true if at least one ShowConsensusHistogram has been added
734    */
735   public boolean hasShowConsensusHistogram()
736   {
737     return this._has_showConsensusHistogram;
738   }
739
740   /**
741    * Method hasShowSequenceLogo.
742    * 
743    * @return true if at least one ShowSequenceLogo has been added
744    */
745   public boolean hasShowSequenceLogo()
746   {
747     return this._has_showSequenceLogo;
748   }
749
750   /**
751    * Method hasShowUnconserved.
752    * 
753    * @return true if at least one ShowUnconserved has been added
754    */
755   public boolean hasShowUnconserved()
756   {
757     return this._has_showUnconserved;
758   }
759
760   /**
761    * Method hasStart.
762    * 
763    * @return true if at least one Start has been added
764    */
765   public boolean hasStart()
766   {
767     return this._has_start;
768   }
769
770   /**
771    * Method hasTextCol1.
772    * 
773    * @return true if at least one TextCol1 has been added
774    */
775   public boolean hasTextCol1()
776   {
777     return this._has_textCol1;
778   }
779
780   /**
781    * Method hasTextCol2.
782    * 
783    * @return true if at least one TextCol2 has been added
784    */
785   public boolean hasTextCol2()
786   {
787     return this._has_textCol2;
788   }
789
790   /**
791    * Method hasTextColThreshold.
792    * 
793    * @return true if at least one TextColThreshold has been added
794    */
795   public boolean hasTextColThreshold()
796   {
797     return this._has_textColThreshold;
798   }
799
800   /**
801    * Returns the value of field 'colourText'.
802    * 
803    * @return the value of field 'ColourText'.
804    */
805   public boolean isColourText()
806   {
807     return this._colourText;
808   }
809
810   /**
811    * Returns the value of field 'displayBoxes'.
812    * 
813    * @return the value of field 'DisplayBoxes'.
814    */
815   public boolean isDisplayBoxes()
816   {
817     return this._displayBoxes;
818   }
819
820   /**
821    * Returns the value of field 'displayText'.
822    * 
823    * @return the value of field 'DisplayText'.
824    */
825   public boolean isDisplayText()
826   {
827     return this._displayText;
828   }
829
830   /**
831    * Returns the value of field 'ignoreGapsinConsensus'.
832    * 
833    * @return the value of field 'IgnoreGapsinConsensus'.
834    */
835   public boolean isIgnoreGapsinConsensus()
836   {
837     return this._ignoreGapsinConsensus;
838   }
839
840   /**
841    * Returns the value of field 'normaliseSequenceLogo'.
842    * 
843    * @return the value of field 'NormaliseSequenceLogo'.
844    */
845   public boolean isNormaliseSequenceLogo()
846   {
847     return this._normaliseSequenceLogo;
848   }
849
850   /**
851    * Returns the value of field 'showConsensusHistogram'.
852    * 
853    * @return the value of field 'ShowConsensusHistogram'.
854    */
855   public boolean isShowConsensusHistogram()
856   {
857     return this._showConsensusHistogram;
858   }
859
860   /**
861    * Returns the value of field 'showSequenceLogo'.
862    * 
863    * @return the value of field 'ShowSequenceLogo'.
864    */
865   public boolean isShowSequenceLogo()
866   {
867     return this._showSequenceLogo;
868   }
869
870   /**
871    * Returns the value of field 'showUnconserved'.
872    * 
873    * @return the value of field 'ShowUnconserved'.
874    */
875   public boolean isShowUnconserved()
876   {
877     return this._showUnconserved;
878   }
879
880   /**
881    * Method isValid.
882    * 
883    * @return true if this object is valid according to the schema
884    */
885   public boolean isValid()
886   {
887     try
888     {
889       validate();
890     } catch (org.exolab.castor.xml.ValidationException vex)
891     {
892       return false;
893     }
894     return true;
895   }
896
897   /**
898    * 
899    * 
900    * @param out
901    * @throws org.exolab.castor.xml.MarshalException
902    *           if object is null or if any SAXException is thrown during
903    *           marshaling
904    * @throws org.exolab.castor.xml.ValidationException
905    *           if this object is an invalid instance according to the schema
906    */
907   public void marshal(final java.io.Writer out)
908           throws org.exolab.castor.xml.MarshalException,
909           org.exolab.castor.xml.ValidationException
910   {
911     Marshaller.marshal(this, out);
912   }
913
914   /**
915    * 
916    * 
917    * @param handler
918    * @throws java.io.IOException
919    *           if an IOException occurs during marshaling
920    * @throws org.exolab.castor.xml.ValidationException
921    *           if this object is an invalid instance according to the schema
922    * @throws org.exolab.castor.xml.MarshalException
923    *           if object is null or if any SAXException is thrown during
924    *           marshaling
925    */
926   public void marshal(final org.xml.sax.ContentHandler handler)
927           throws java.io.IOException,
928           org.exolab.castor.xml.MarshalException,
929           org.exolab.castor.xml.ValidationException
930   {
931     Marshaller.marshal(this, handler);
932   }
933
934   /**
935      */
936   public void removeAllSeq()
937   {
938     this._seqList.clear();
939   }
940
941   /**
942    * Method removeSeq.
943    * 
944    * @param vSeq
945    * @return true if the object was removed from the collection.
946    */
947   public boolean removeSeq(final java.lang.String vSeq)
948   {
949     boolean removed = _seqList.remove(vSeq);
950     return removed;
951   }
952
953   /**
954    * Method removeSeqAt.
955    * 
956    * @param index
957    * @return the element removed from the collection
958    */
959   public java.lang.String removeSeqAt(final int index)
960   {
961     java.lang.Object obj = this._seqList.remove(index);
962     return (java.lang.String) obj;
963   }
964
965   /**
966    * Sets the value of field 'annotationColours'.
967    * 
968    * @param annotationColours
969    *          the value of field 'annotationColours'.
970    */
971   public void setAnnotationColours(
972           final jalview.schemabinding.version2.AnnotationColours annotationColours)
973   {
974     this._annotationColours = annotationColours;
975   }
976
977   /**
978    * Sets the value of field 'colour'.
979    * 
980    * @param colour
981    *          the value of field 'colour'.
982    */
983   public void setColour(final java.lang.String colour)
984   {
985     this._colour = colour;
986   }
987
988   /**
989    * Sets the value of field 'colourText'.
990    * 
991    * @param colourText
992    *          the value of field 'colourText'.
993    */
994   public void setColourText(final boolean colourText)
995   {
996     this._colourText = colourText;
997     this._has_colourText = true;
998   }
999
1000   /**
1001    * Sets the value of field 'consThreshold'.
1002    * 
1003    * @param consThreshold
1004    *          the value of field 'consThreshold'.
1005    */
1006   public void setConsThreshold(final int consThreshold)
1007   {
1008     this._consThreshold = consThreshold;
1009     this._has_consThreshold = true;
1010   }
1011
1012   /**
1013    * Sets the value of field 'displayBoxes'.
1014    * 
1015    * @param displayBoxes
1016    *          the value of field 'displayBoxes'.
1017    */
1018   public void setDisplayBoxes(final boolean displayBoxes)
1019   {
1020     this._displayBoxes = displayBoxes;
1021     this._has_displayBoxes = true;
1022   }
1023
1024   /**
1025    * Sets the value of field 'displayText'.
1026    * 
1027    * @param displayText
1028    *          the value of field 'displayText'.
1029    */
1030   public void setDisplayText(final boolean displayText)
1031   {
1032     this._displayText = displayText;
1033     this._has_displayText = true;
1034   }
1035
1036   /**
1037    * Sets the value of field 'end'.
1038    * 
1039    * @param end
1040    *          the value of field 'end'.
1041    */
1042   public void setEnd(final int end)
1043   {
1044     this._end = end;
1045     this._has_end = true;
1046   }
1047
1048   /**
1049    * Sets the value of field 'id'. The field 'id' has the following description:
1050    * Optional sequence group ID (only needs to be unique for this alignment)
1051    * 
1052    * 
1053    * @param id
1054    *          the value of field 'id'.
1055    */
1056   public void setId(final java.lang.String id)
1057   {
1058     this._id = id;
1059   }
1060
1061   /**
1062    * Sets the value of field 'ignoreGapsinConsensus'.
1063    * 
1064    * @param ignoreGapsinConsensus
1065    *          the value of field 'ignoreGapsinConsensus'.
1066    */
1067   public void setIgnoreGapsinConsensus(final boolean ignoreGapsinConsensus)
1068   {
1069     this._ignoreGapsinConsensus = ignoreGapsinConsensus;
1070     this._has_ignoreGapsinConsensus = true;
1071   }
1072
1073   /**
1074    * Sets the value of field 'name'.
1075    * 
1076    * @param name
1077    *          the value of field 'name'.
1078    */
1079   public void setName(final java.lang.String name)
1080   {
1081     this._name = name;
1082   }
1083
1084   /**
1085    * Sets the value of field 'normaliseSequenceLogo'.
1086    * 
1087    * @param normaliseSequenceLogo
1088    *          the value of field 'normaliseSequenceLogo'.
1089    */
1090   public void setNormaliseSequenceLogo(final boolean normaliseSequenceLogo)
1091   {
1092     this._normaliseSequenceLogo = normaliseSequenceLogo;
1093     this._has_normaliseSequenceLogo = true;
1094   }
1095
1096   /**
1097    * Sets the value of field 'outlineColour'.
1098    * 
1099    * @param outlineColour
1100    *          the value of field 'outlineColour'.
1101    */
1102   public void setOutlineColour(final int outlineColour)
1103   {
1104     this._outlineColour = outlineColour;
1105     this._has_outlineColour = true;
1106   }
1107
1108   /**
1109    * Sets the value of field 'pidThreshold'.
1110    * 
1111    * @param pidThreshold
1112    *          the value of field 'pidThreshold'.
1113    */
1114   public void setPidThreshold(final int pidThreshold)
1115   {
1116     this._pidThreshold = pidThreshold;
1117     this._has_pidThreshold = true;
1118   }
1119
1120   /**
1121    * 
1122    * 
1123    * @param index
1124    * @param vSeq
1125    * @throws java.lang.IndexOutOfBoundsException
1126    *           if the index given is outside the bounds of the collection
1127    */
1128   public void setSeq(final int index, final java.lang.String vSeq)
1129           throws java.lang.IndexOutOfBoundsException
1130   {
1131     // check bounds for index
1132     if (index < 0 || index >= this._seqList.size())
1133     {
1134       throw new IndexOutOfBoundsException("setSeq: Index value '" + index
1135               + "' not in range [0.." + (this._seqList.size() - 1) + "]");
1136     }
1137
1138     this._seqList.set(index, vSeq);
1139   }
1140
1141   /**
1142    * 
1143    * 
1144    * @param vSeqArray
1145    */
1146   public void setSeq(final java.lang.String[] vSeqArray)
1147   {
1148     // -- copy array
1149     _seqList.clear();
1150
1151     for (int i = 0; i < vSeqArray.length; i++)
1152     {
1153       this._seqList.add(vSeqArray[i]);
1154     }
1155   }
1156
1157   /**
1158    * Sets the value of field 'showConsensusHistogram'.
1159    * 
1160    * @param showConsensusHistogram
1161    *          the value of field 'showConsensusHistogram'.
1162    */
1163   public void setShowConsensusHistogram(final boolean showConsensusHistogram)
1164   {
1165     this._showConsensusHistogram = showConsensusHistogram;
1166     this._has_showConsensusHistogram = true;
1167   }
1168
1169   /**
1170    * Sets the value of field 'showSequenceLogo'.
1171    * 
1172    * @param showSequenceLogo
1173    *          the value of field 'showSequenceLogo'
1174    */
1175   public void setShowSequenceLogo(final boolean showSequenceLogo)
1176   {
1177     this._showSequenceLogo = showSequenceLogo;
1178     this._has_showSequenceLogo = true;
1179   }
1180
1181   /**
1182    * Sets the value of field 'showUnconserved'.
1183    * 
1184    * @param showUnconserved
1185    *          the value of field 'showUnconserved'.
1186    */
1187   public void setShowUnconserved(final boolean showUnconserved)
1188   {
1189     this._showUnconserved = showUnconserved;
1190     this._has_showUnconserved = true;
1191   }
1192
1193   /**
1194    * Sets the value of field 'start'.
1195    * 
1196    * @param start
1197    *          the value of field 'start'.
1198    */
1199   public void setStart(final int start)
1200   {
1201     this._start = start;
1202     this._has_start = true;
1203   }
1204
1205   /**
1206    * Sets the value of field 'textCol1'.
1207    * 
1208    * @param textCol1
1209    *          the value of field 'textCol1'.
1210    */
1211   public void setTextCol1(final int textCol1)
1212   {
1213     this._textCol1 = textCol1;
1214     this._has_textCol1 = true;
1215   }
1216
1217   /**
1218    * Sets the value of field 'textCol2'.
1219    * 
1220    * @param textCol2
1221    *          the value of field 'textCol2'.
1222    */
1223   public void setTextCol2(final int textCol2)
1224   {
1225     this._textCol2 = textCol2;
1226     this._has_textCol2 = true;
1227   }
1228
1229   /**
1230    * Sets the value of field 'textColThreshold'.
1231    * 
1232    * @param textColThreshold
1233    *          the value of field 'textColThreshold'
1234    */
1235   public void setTextColThreshold(final int textColThreshold)
1236   {
1237     this._textColThreshold = textColThreshold;
1238     this._has_textColThreshold = true;
1239   }
1240
1241   /**
1242    * Method unmarshal.
1243    * 
1244    * @param reader
1245    * @throws org.exolab.castor.xml.MarshalException
1246    *           if object is null or if any SAXException is thrown during
1247    *           marshaling
1248    * @throws org.exolab.castor.xml.ValidationException
1249    *           if this object is an invalid instance according to the schema
1250    * @return the unmarshaled jalview.schemabinding.version2.JGroup
1251    */
1252   public static jalview.schemabinding.version2.JGroup unmarshal(
1253           final java.io.Reader reader)
1254           throws org.exolab.castor.xml.MarshalException,
1255           org.exolab.castor.xml.ValidationException
1256   {
1257     return (jalview.schemabinding.version2.JGroup) Unmarshaller.unmarshal(
1258             jalview.schemabinding.version2.JGroup.class, reader);
1259   }
1260
1261   /**
1262    * 
1263    * 
1264    * @throws org.exolab.castor.xml.ValidationException
1265    *           if this object is an invalid instance according to the schema
1266    */
1267   public void validate() throws org.exolab.castor.xml.ValidationException
1268   {
1269     org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
1270     validator.validate(this);
1271   }
1272
1273 }