c24533e7288776264a9cf68f3252c620ba818d6c
[jalview.git] / src / jalview / schemabinding / version2 / JGroup.java
1 /*\r
2  * Jalview - A Sequence Alignment Editor and Viewer (Version 2.4)\r
3  * Copyright (C) 2008 AM Waterhouse, J Procter, G Barton, M Clamp, S Searle\r
4  * \r
5  * This program is free software; you can redistribute it and/or\r
6  * modify it under the terms of the GNU General Public License\r
7  * as published by the Free Software Foundation; either version 2\r
8  * of the License, or (at your option) any later version.\r
9  * \r
10  * This program is distributed in the hope that it will be useful,\r
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of\r
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\r
13  * GNU General Public License for more details.\r
14  * \r
15  * You should have received a copy of the GNU General Public License\r
16  * along with this program; if not, write to the Free Software\r
17  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA\r
18  */\r
19 package jalview.schemabinding.version2;\r
20 \r
21 // ---------------------------------/\r
22 // - Imported classes and packages -/\r
23 // ---------------------------------/\r
24 \r
25 import org.exolab.castor.xml.Marshaller;\r
26 import org.exolab.castor.xml.Unmarshaller;\r
27 \r
28 /**\r
29  * Class JGroup.\r
30  * \r
31  * @version $Revision$ $Date$\r
32  */\r
33 public class JGroup implements java.io.Serializable\r
34 {\r
35 \r
36   // --------------------------/\r
37   // - Class/Member Variables -/\r
38   // --------------------------/\r
39 \r
40   /**\r
41    * Field _start.\r
42    */\r
43   private int _start;\r
44 \r
45   /**\r
46    * keeps track of state for field: _start\r
47    */\r
48   private boolean _has_start;\r
49 \r
50   /**\r
51    * Field _end.\r
52    */\r
53   private int _end;\r
54 \r
55   /**\r
56    * keeps track of state for field: _end\r
57    */\r
58   private boolean _has_end;\r
59 \r
60   /**\r
61    * Field _name.\r
62    */\r
63   private java.lang.String _name;\r
64 \r
65   /**\r
66    * Field _colour.\r
67    */\r
68   private java.lang.String _colour;\r
69 \r
70   /**\r
71    * Field _consThreshold.\r
72    */\r
73   private int _consThreshold;\r
74 \r
75   /**\r
76    * keeps track of state for field: _consThreshold\r
77    */\r
78   private boolean _has_consThreshold;\r
79 \r
80   /**\r
81    * Field _pidThreshold.\r
82    */\r
83   private int _pidThreshold;\r
84 \r
85   /**\r
86    * keeps track of state for field: _pidThreshold\r
87    */\r
88   private boolean _has_pidThreshold;\r
89 \r
90   /**\r
91    * Field _outlineColour.\r
92    */\r
93   private int _outlineColour;\r
94 \r
95   /**\r
96    * keeps track of state for field: _outlineColour\r
97    */\r
98   private boolean _has_outlineColour;\r
99 \r
100   /**\r
101    * Field _displayBoxes.\r
102    */\r
103   private boolean _displayBoxes;\r
104 \r
105   /**\r
106    * keeps track of state for field: _displayBoxes\r
107    */\r
108   private boolean _has_displayBoxes;\r
109 \r
110   /**\r
111    * Field _displayText.\r
112    */\r
113   private boolean _displayText;\r
114 \r
115   /**\r
116    * keeps track of state for field: _displayText\r
117    */\r
118   private boolean _has_displayText;\r
119 \r
120   /**\r
121    * Field _colourText.\r
122    */\r
123   private boolean _colourText;\r
124 \r
125   /**\r
126    * keeps track of state for field: _colourText\r
127    */\r
128   private boolean _has_colourText;\r
129 \r
130   /**\r
131    * Field _textCol1.\r
132    */\r
133   private int _textCol1;\r
134 \r
135   /**\r
136    * keeps track of state for field: _textCol1\r
137    */\r
138   private boolean _has_textCol1;\r
139 \r
140   /**\r
141    * Field _textCol2.\r
142    */\r
143   private int _textCol2;\r
144 \r
145   /**\r
146    * keeps track of state for field: _textCol2\r
147    */\r
148   private boolean _has_textCol2;\r
149 \r
150   /**\r
151    * Field _textColThreshold.\r
152    */\r
153   private int _textColThreshold;\r
154 \r
155   /**\r
156    * keeps track of state for field: _textColThreshold\r
157    */\r
158   private boolean _has_textColThreshold;\r
159 \r
160   /**\r
161    * Field _seqList.\r
162    */\r
163   private java.util.Vector _seqList;\r
164 \r
165   // ----------------/\r
166   // - Constructors -/\r
167   // ----------------/\r
168 \r
169   public JGroup()\r
170   {\r
171     super();\r
172     this._seqList = new java.util.Vector();\r
173   }\r
174 \r
175   // -----------/\r
176   // - Methods -/\r
177   // -----------/\r
178 \r
179   /**\r
180    * \r
181    * \r
182    * @param vSeq\r
183    * @throws java.lang.IndexOutOfBoundsException\r
184    *                 if the index given is outside the bounds of the collection\r
185    */\r
186   public void addSeq(final java.lang.String vSeq)\r
187           throws java.lang.IndexOutOfBoundsException\r
188   {\r
189     this._seqList.addElement(vSeq);\r
190   }\r
191 \r
192   /**\r
193    * \r
194    * \r
195    * @param index\r
196    * @param vSeq\r
197    * @throws java.lang.IndexOutOfBoundsException\r
198    *                 if the index given is outside the bounds of the collection\r
199    */\r
200   public void addSeq(final int index, final java.lang.String vSeq)\r
201           throws java.lang.IndexOutOfBoundsException\r
202   {\r
203     this._seqList.add(index, vSeq);\r
204   }\r
205 \r
206   /**\r
207    */\r
208   public void deleteColourText()\r
209   {\r
210     this._has_colourText = false;\r
211   }\r
212 \r
213   /**\r
214    */\r
215   public void deleteConsThreshold()\r
216   {\r
217     this._has_consThreshold = false;\r
218   }\r
219 \r
220   /**\r
221    */\r
222   public void deleteDisplayBoxes()\r
223   {\r
224     this._has_displayBoxes = false;\r
225   }\r
226 \r
227   /**\r
228    */\r
229   public void deleteDisplayText()\r
230   {\r
231     this._has_displayText = false;\r
232   }\r
233 \r
234   /**\r
235    */\r
236   public void deleteEnd()\r
237   {\r
238     this._has_end = false;\r
239   }\r
240 \r
241   /**\r
242    */\r
243   public void deleteOutlineColour()\r
244   {\r
245     this._has_outlineColour = false;\r
246   }\r
247 \r
248   /**\r
249    */\r
250   public void deletePidThreshold()\r
251   {\r
252     this._has_pidThreshold = false;\r
253   }\r
254 \r
255   /**\r
256    */\r
257   public void deleteStart()\r
258   {\r
259     this._has_start = false;\r
260   }\r
261 \r
262   /**\r
263    */\r
264   public void deleteTextCol1()\r
265   {\r
266     this._has_textCol1 = false;\r
267   }\r
268 \r
269   /**\r
270    */\r
271   public void deleteTextCol2()\r
272   {\r
273     this._has_textCol2 = false;\r
274   }\r
275 \r
276   /**\r
277    */\r
278   public void deleteTextColThreshold()\r
279   {\r
280     this._has_textColThreshold = false;\r
281   }\r
282 \r
283   /**\r
284    * Method enumerateSeq.\r
285    * \r
286    * @return an Enumeration over all java.lang.String elements\r
287    */\r
288   public java.util.Enumeration enumerateSeq()\r
289   {\r
290     return this._seqList.elements();\r
291   }\r
292 \r
293   /**\r
294    * Returns the value of field 'colour'.\r
295    * \r
296    * @return the value of field 'Colour'.\r
297    */\r
298   public java.lang.String getColour()\r
299   {\r
300     return this._colour;\r
301   }\r
302 \r
303   /**\r
304    * Returns the value of field 'colourText'.\r
305    * \r
306    * @return the value of field 'ColourText'.\r
307    */\r
308   public boolean getColourText()\r
309   {\r
310     return this._colourText;\r
311   }\r
312 \r
313   /**\r
314    * Returns the value of field 'consThreshold'.\r
315    * \r
316    * @return the value of field 'ConsThreshold'.\r
317    */\r
318   public int getConsThreshold()\r
319   {\r
320     return this._consThreshold;\r
321   }\r
322 \r
323   /**\r
324    * Returns the value of field 'displayBoxes'.\r
325    * \r
326    * @return the value of field 'DisplayBoxes'.\r
327    */\r
328   public boolean getDisplayBoxes()\r
329   {\r
330     return this._displayBoxes;\r
331   }\r
332 \r
333   /**\r
334    * Returns the value of field 'displayText'.\r
335    * \r
336    * @return the value of field 'DisplayText'.\r
337    */\r
338   public boolean getDisplayText()\r
339   {\r
340     return this._displayText;\r
341   }\r
342 \r
343   /**\r
344    * Returns the value of field 'end'.\r
345    * \r
346    * @return the value of field 'End'.\r
347    */\r
348   public int getEnd()\r
349   {\r
350     return this._end;\r
351   }\r
352 \r
353   /**\r
354    * Returns the value of field 'name'.\r
355    * \r
356    * @return the value of field 'Name'.\r
357    */\r
358   public java.lang.String getName()\r
359   {\r
360     return this._name;\r
361   }\r
362 \r
363   /**\r
364    * Returns the value of field 'outlineColour'.\r
365    * \r
366    * @return the value of field 'OutlineColour'.\r
367    */\r
368   public int getOutlineColour()\r
369   {\r
370     return this._outlineColour;\r
371   }\r
372 \r
373   /**\r
374    * Returns the value of field 'pidThreshold'.\r
375    * \r
376    * @return the value of field 'PidThreshold'.\r
377    */\r
378   public int getPidThreshold()\r
379   {\r
380     return this._pidThreshold;\r
381   }\r
382 \r
383   /**\r
384    * Method getSeq.\r
385    * \r
386    * @param index\r
387    * @throws java.lang.IndexOutOfBoundsException\r
388    *                 if the index given is outside the bounds of the collection\r
389    * @return the value of the java.lang.String at the given index\r
390    */\r
391   public java.lang.String getSeq(final int index)\r
392           throws java.lang.IndexOutOfBoundsException\r
393   {\r
394     // check bounds for index\r
395     if (index < 0 || index >= this._seqList.size())\r
396     {\r
397       throw new IndexOutOfBoundsException("getSeq: Index value '" + index\r
398               + "' not in range [0.." + (this._seqList.size() - 1) + "]");\r
399     }\r
400 \r
401     return (java.lang.String) _seqList.get(index);\r
402   }\r
403 \r
404   /**\r
405    * Method getSeq.Returns the contents of the collection in an Array.\r
406    * <p>\r
407    * Note: Just in case the collection contents are changing in another thread,\r
408    * we pass a 0-length Array of the correct type into the API call. This way we\r
409    * <i>know</i> that the Array returned is of exactly the correct length.\r
410    * \r
411    * @return this collection as an Array\r
412    */\r
413   public java.lang.String[] getSeq()\r
414   {\r
415     java.lang.String[] array = new java.lang.String[0];\r
416     return (java.lang.String[]) this._seqList.toArray(array);\r
417   }\r
418 \r
419   /**\r
420    * Method getSeqCount.\r
421    * \r
422    * @return the size of this collection\r
423    */\r
424   public int getSeqCount()\r
425   {\r
426     return this._seqList.size();\r
427   }\r
428 \r
429   /**\r
430    * Returns the value of field 'start'.\r
431    * \r
432    * @return the value of field 'Start'.\r
433    */\r
434   public int getStart()\r
435   {\r
436     return this._start;\r
437   }\r
438 \r
439   /**\r
440    * Returns the value of field 'textCol1'.\r
441    * \r
442    * @return the value of field 'TextCol1'.\r
443    */\r
444   public int getTextCol1()\r
445   {\r
446     return this._textCol1;\r
447   }\r
448 \r
449   /**\r
450    * Returns the value of field 'textCol2'.\r
451    * \r
452    * @return the value of field 'TextCol2'.\r
453    */\r
454   public int getTextCol2()\r
455   {\r
456     return this._textCol2;\r
457   }\r
458 \r
459   /**\r
460    * Returns the value of field 'textColThreshold'.\r
461    * \r
462    * @return the value of field 'TextColThreshold'.\r
463    */\r
464   public int getTextColThreshold()\r
465   {\r
466     return this._textColThreshold;\r
467   }\r
468 \r
469   /**\r
470    * Method hasColourText.\r
471    * \r
472    * @return true if at least one ColourText has been added\r
473    */\r
474   public boolean hasColourText()\r
475   {\r
476     return this._has_colourText;\r
477   }\r
478 \r
479   /**\r
480    * Method hasConsThreshold.\r
481    * \r
482    * @return true if at least one ConsThreshold has been added\r
483    */\r
484   public boolean hasConsThreshold()\r
485   {\r
486     return this._has_consThreshold;\r
487   }\r
488 \r
489   /**\r
490    * Method hasDisplayBoxes.\r
491    * \r
492    * @return true if at least one DisplayBoxes has been added\r
493    */\r
494   public boolean hasDisplayBoxes()\r
495   {\r
496     return this._has_displayBoxes;\r
497   }\r
498 \r
499   /**\r
500    * Method hasDisplayText.\r
501    * \r
502    * @return true if at least one DisplayText has been added\r
503    */\r
504   public boolean hasDisplayText()\r
505   {\r
506     return this._has_displayText;\r
507   }\r
508 \r
509   /**\r
510    * Method hasEnd.\r
511    * \r
512    * @return true if at least one End has been added\r
513    */\r
514   public boolean hasEnd()\r
515   {\r
516     return this._has_end;\r
517   }\r
518 \r
519   /**\r
520    * Method hasOutlineColour.\r
521    * \r
522    * @return true if at least one OutlineColour has been added\r
523    */\r
524   public boolean hasOutlineColour()\r
525   {\r
526     return this._has_outlineColour;\r
527   }\r
528 \r
529   /**\r
530    * Method hasPidThreshold.\r
531    * \r
532    * @return true if at least one PidThreshold has been added\r
533    */\r
534   public boolean hasPidThreshold()\r
535   {\r
536     return this._has_pidThreshold;\r
537   }\r
538 \r
539   /**\r
540    * Method hasStart.\r
541    * \r
542    * @return true if at least one Start has been added\r
543    */\r
544   public boolean hasStart()\r
545   {\r
546     return this._has_start;\r
547   }\r
548 \r
549   /**\r
550    * Method hasTextCol1.\r
551    * \r
552    * @return true if at least one TextCol1 has been added\r
553    */\r
554   public boolean hasTextCol1()\r
555   {\r
556     return this._has_textCol1;\r
557   }\r
558 \r
559   /**\r
560    * Method hasTextCol2.\r
561    * \r
562    * @return true if at least one TextCol2 has been added\r
563    */\r
564   public boolean hasTextCol2()\r
565   {\r
566     return this._has_textCol2;\r
567   }\r
568 \r
569   /**\r
570    * Method hasTextColThreshold.\r
571    * \r
572    * @return true if at least one TextColThreshold has been added\r
573    */\r
574   public boolean hasTextColThreshold()\r
575   {\r
576     return this._has_textColThreshold;\r
577   }\r
578 \r
579   /**\r
580    * Returns the value of field 'colourText'.\r
581    * \r
582    * @return the value of field 'ColourText'.\r
583    */\r
584   public boolean isColourText()\r
585   {\r
586     return this._colourText;\r
587   }\r
588 \r
589   /**\r
590    * Returns the value of field 'displayBoxes'.\r
591    * \r
592    * @return the value of field 'DisplayBoxes'.\r
593    */\r
594   public boolean isDisplayBoxes()\r
595   {\r
596     return this._displayBoxes;\r
597   }\r
598 \r
599   /**\r
600    * Returns the value of field 'displayText'.\r
601    * \r
602    * @return the value of field 'DisplayText'.\r
603    */\r
604   public boolean isDisplayText()\r
605   {\r
606     return this._displayText;\r
607   }\r
608 \r
609   /**\r
610    * Method isValid.\r
611    * \r
612    * @return true if this object is valid according to the schema\r
613    */\r
614   public boolean isValid()\r
615   {\r
616     try\r
617     {\r
618       validate();\r
619     } catch (org.exolab.castor.xml.ValidationException vex)\r
620     {\r
621       return false;\r
622     }\r
623     return true;\r
624   }\r
625 \r
626   /**\r
627    * \r
628    * \r
629    * @param out\r
630    * @throws org.exolab.castor.xml.MarshalException\r
631    *                 if object is null or if any SAXException is thrown during\r
632    *                 marshaling\r
633    * @throws org.exolab.castor.xml.ValidationException\r
634    *                 if this object is an invalid instance according to the\r
635    *                 schema\r
636    */\r
637   public void marshal(final java.io.Writer out)\r
638           throws org.exolab.castor.xml.MarshalException,\r
639           org.exolab.castor.xml.ValidationException\r
640   {\r
641     Marshaller.marshal(this, out);\r
642   }\r
643 \r
644   /**\r
645    * \r
646    * \r
647    * @param handler\r
648    * @throws java.io.IOException\r
649    *                 if an IOException occurs during marshaling\r
650    * @throws org.exolab.castor.xml.ValidationException\r
651    *                 if this object is an invalid instance according to the\r
652    *                 schema\r
653    * @throws org.exolab.castor.xml.MarshalException\r
654    *                 if object is null or if any SAXException is thrown during\r
655    *                 marshaling\r
656    */\r
657   public void marshal(final org.xml.sax.ContentHandler handler)\r
658           throws java.io.IOException,\r
659           org.exolab.castor.xml.MarshalException,\r
660           org.exolab.castor.xml.ValidationException\r
661   {\r
662     Marshaller.marshal(this, handler);\r
663   }\r
664 \r
665   /**\r
666    */\r
667   public void removeAllSeq()\r
668   {\r
669     this._seqList.clear();\r
670   }\r
671 \r
672   /**\r
673    * Method removeSeq.\r
674    * \r
675    * @param vSeq\r
676    * @return true if the object was removed from the collection.\r
677    */\r
678   public boolean removeSeq(final java.lang.String vSeq)\r
679   {\r
680     boolean removed = _seqList.remove(vSeq);\r
681     return removed;\r
682   }\r
683 \r
684   /**\r
685    * Method removeSeqAt.\r
686    * \r
687    * @param index\r
688    * @return the element removed from the collection\r
689    */\r
690   public java.lang.String removeSeqAt(final int index)\r
691   {\r
692     java.lang.Object obj = this._seqList.remove(index);\r
693     return (java.lang.String) obj;\r
694   }\r
695 \r
696   /**\r
697    * Sets the value of field 'colour'.\r
698    * \r
699    * @param colour\r
700    *                the value of field 'colour'.\r
701    */\r
702   public void setColour(final java.lang.String colour)\r
703   {\r
704     this._colour = colour;\r
705   }\r
706 \r
707   /**\r
708    * Sets the value of field 'colourText'.\r
709    * \r
710    * @param colourText\r
711    *                the value of field 'colourText'.\r
712    */\r
713   public void setColourText(final boolean colourText)\r
714   {\r
715     this._colourText = colourText;\r
716     this._has_colourText = true;\r
717   }\r
718 \r
719   /**\r
720    * Sets the value of field 'consThreshold'.\r
721    * \r
722    * @param consThreshold\r
723    *                the value of field 'consThreshold'.\r
724    */\r
725   public void setConsThreshold(final int consThreshold)\r
726   {\r
727     this._consThreshold = consThreshold;\r
728     this._has_consThreshold = true;\r
729   }\r
730 \r
731   /**\r
732    * Sets the value of field 'displayBoxes'.\r
733    * \r
734    * @param displayBoxes\r
735    *                the value of field 'displayBoxes'.\r
736    */\r
737   public void setDisplayBoxes(final boolean displayBoxes)\r
738   {\r
739     this._displayBoxes = displayBoxes;\r
740     this._has_displayBoxes = true;\r
741   }\r
742 \r
743   /**\r
744    * Sets the value of field 'displayText'.\r
745    * \r
746    * @param displayText\r
747    *                the value of field 'displayText'.\r
748    */\r
749   public void setDisplayText(final boolean displayText)\r
750   {\r
751     this._displayText = displayText;\r
752     this._has_displayText = true;\r
753   }\r
754 \r
755   /**\r
756    * Sets the value of field 'end'.\r
757    * \r
758    * @param end\r
759    *                the value of field 'end'.\r
760    */\r
761   public void setEnd(final int end)\r
762   {\r
763     this._end = end;\r
764     this._has_end = true;\r
765   }\r
766 \r
767   /**\r
768    * Sets the value of field 'name'.\r
769    * \r
770    * @param name\r
771    *                the value of field 'name'.\r
772    */\r
773   public void setName(final java.lang.String name)\r
774   {\r
775     this._name = name;\r
776   }\r
777 \r
778   /**\r
779    * Sets the value of field 'outlineColour'.\r
780    * \r
781    * @param outlineColour\r
782    *                the value of field 'outlineColour'.\r
783    */\r
784   public void setOutlineColour(final int outlineColour)\r
785   {\r
786     this._outlineColour = outlineColour;\r
787     this._has_outlineColour = true;\r
788   }\r
789 \r
790   /**\r
791    * Sets the value of field 'pidThreshold'.\r
792    * \r
793    * @param pidThreshold\r
794    *                the value of field 'pidThreshold'.\r
795    */\r
796   public void setPidThreshold(final int pidThreshold)\r
797   {\r
798     this._pidThreshold = pidThreshold;\r
799     this._has_pidThreshold = true;\r
800   }\r
801 \r
802   /**\r
803    * \r
804    * \r
805    * @param index\r
806    * @param vSeq\r
807    * @throws java.lang.IndexOutOfBoundsException\r
808    *                 if the index given is outside the bounds of the collection\r
809    */\r
810   public void setSeq(final int index, final java.lang.String vSeq)\r
811           throws java.lang.IndexOutOfBoundsException\r
812   {\r
813     // check bounds for index\r
814     if (index < 0 || index >= this._seqList.size())\r
815     {\r
816       throw new IndexOutOfBoundsException("setSeq: Index value '" + index\r
817               + "' not in range [0.." + (this._seqList.size() - 1) + "]");\r
818     }\r
819 \r
820     this._seqList.set(index, vSeq);\r
821   }\r
822 \r
823   /**\r
824    * \r
825    * \r
826    * @param vSeqArray\r
827    */\r
828   public void setSeq(final java.lang.String[] vSeqArray)\r
829   {\r
830     // -- copy array\r
831     _seqList.clear();\r
832 \r
833     for (int i = 0; i < vSeqArray.length; i++)\r
834     {\r
835       this._seqList.add(vSeqArray[i]);\r
836     }\r
837   }\r
838 \r
839   /**\r
840    * Sets the value of field 'start'.\r
841    * \r
842    * @param start\r
843    *                the value of field 'start'.\r
844    */\r
845   public void setStart(final int start)\r
846   {\r
847     this._start = start;\r
848     this._has_start = true;\r
849   }\r
850 \r
851   /**\r
852    * Sets the value of field 'textCol1'.\r
853    * \r
854    * @param textCol1\r
855    *                the value of field 'textCol1'.\r
856    */\r
857   public void setTextCol1(final int textCol1)\r
858   {\r
859     this._textCol1 = textCol1;\r
860     this._has_textCol1 = true;\r
861   }\r
862 \r
863   /**\r
864    * Sets the value of field 'textCol2'.\r
865    * \r
866    * @param textCol2\r
867    *                the value of field 'textCol2'.\r
868    */\r
869   public void setTextCol2(final int textCol2)\r
870   {\r
871     this._textCol2 = textCol2;\r
872     this._has_textCol2 = true;\r
873   }\r
874 \r
875   /**\r
876    * Sets the value of field 'textColThreshold'.\r
877    * \r
878    * @param textColThreshold\r
879    *                the value of field 'textColThreshold'\r
880    */\r
881   public void setTextColThreshold(final int textColThreshold)\r
882   {\r
883     this._textColThreshold = textColThreshold;\r
884     this._has_textColThreshold = true;\r
885   }\r
886 \r
887   /**\r
888    * Method unmarshal.\r
889    * \r
890    * @param reader\r
891    * @throws org.exolab.castor.xml.MarshalException\r
892    *                 if object is null or if any SAXException is thrown during\r
893    *                 marshaling\r
894    * @throws org.exolab.castor.xml.ValidationException\r
895    *                 if this object is an invalid instance according to the\r
896    *                 schema\r
897    * @return the unmarshaled jalview.schemabinding.version2.JGroup\r
898    */\r
899   public static jalview.schemabinding.version2.JGroup unmarshal(\r
900           final java.io.Reader reader)\r
901           throws org.exolab.castor.xml.MarshalException,\r
902           org.exolab.castor.xml.ValidationException\r
903   {\r
904     return (jalview.schemabinding.version2.JGroup) Unmarshaller.unmarshal(\r
905             jalview.schemabinding.version2.JGroup.class, reader);\r
906   }\r
907 \r
908   /**\r
909    * \r
910    * \r
911    * @throws org.exolab.castor.xml.ValidationException\r
912    *                 if this object is an invalid instance according to the\r
913    *                 schema\r
914    */\r
915   public void validate() throws org.exolab.castor.xml.ValidationException\r
916   {\r
917     org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();\r
918     validator.validate(this);\r
919   }\r
920 \r
921 }\r