22ab909cf3575848fa00579761050e6eb2826ea3
[jalview.git] / src / jalview / schemabinding / version2 / Annotation.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 Annotation.
19  * 
20  * @version $Revision$ $Date$
21  */
22 public class Annotation implements java.io.Serializable
23 {
24
25   // --------------------------/
26   // - Class/Member Variables -/
27   // --------------------------/
28
29   /**
30    * Field _graph.
31    */
32   private boolean _graph;
33
34   /**
35    * keeps track of state for field: _graph
36    */
37   private boolean _has_graph;
38
39   /**
40    * Field _graphType.
41    */
42   private int _graphType;
43
44   /**
45    * keeps track of state for field: _graphType
46    */
47   private boolean _has_graphType;
48
49   /**
50    * Field _sequenceRef.
51    */
52   private java.lang.String _sequenceRef;
53
54   /**
55    * Field _groupRef.
56    */
57   private java.lang.String _groupRef;
58
59   /**
60    * Field _graphColour.
61    */
62   private int _graphColour;
63
64   /**
65    * keeps track of state for field: _graphColour
66    */
67   private boolean _has_graphColour;
68
69   /**
70    * Field _graphGroup.
71    */
72   private int _graphGroup;
73
74   /**
75    * keeps track of state for field: _graphGroup
76    */
77   private boolean _has_graphGroup;
78
79   /**
80    * height in pixels for the graph if this is a graph-type annotation.
81    */
82   private int _graphHeight;
83
84   /**
85    * keeps track of state for field: _graphHeight
86    */
87   private boolean _has_graphHeight;
88
89   /**
90    * Field _id.
91    */
92   private java.lang.String _id;
93
94   /**
95    * Field _scoreOnly.
96    */
97   private boolean _scoreOnly = false;
98
99   /**
100    * keeps track of state for field: _scoreOnly
101    */
102   private boolean _has_scoreOnly;
103
104   /**
105    * Field _score.
106    */
107   private double _score;
108
109   /**
110    * keeps track of state for field: _score
111    */
112   private boolean _has_score;
113
114   /**
115    * Field _visible.
116    */
117   private boolean _visible;
118
119   /**
120    * keeps track of state for field: _visible
121    */
122   private boolean _has_visible;
123
124   /**
125    * Field _centreColLabels.
126    */
127   private boolean _centreColLabels;
128
129   /**
130    * keeps track of state for field: _centreColLabels
131    */
132   private boolean _has_centreColLabels;
133
134   /**
135    * Field _scaleColLabels.
136    */
137   private boolean _scaleColLabels;
138
139   /**
140    * keeps track of state for field: _scaleColLabels
141    */
142   private boolean _has_scaleColLabels;
143
144   /**
145    * Field _showAllColLabels.
146    */
147   private boolean _showAllColLabels;
148
149   /**
150    * keeps track of state for field: _showAllColLabels
151    */
152   private boolean _has_showAllColLabels;
153
154   /**
155    * is an autocalculated annotation row
156    */
157   private boolean _autoCalculated = false;
158
159   /**
160    * keeps track of state for field: _autoCalculated
161    */
162   private boolean _has_autoCalculated;
163
164   /**
165    * is to be shown below the alignment - introduced in Jalview 2.8 for
166    * visualizing T-COFFEE alignment scores
167    */
168   private boolean _belowAlignment = true;
169
170   /**
171    * keeps track of state for field: _belowAlignment
172    */
173   private boolean _has_belowAlignment;
174
175   /**
176    * Optional string identifier used to group sets of annotation produced by a
177    * particular calculation. Values are opaque strings but have semantic meaning
178    * to Jalview's renderer, data importer and calculation system.
179    */
180   private java.lang.String _calcId;
181
182   /**
183    * Field _annotationElementList.
184    */
185   private java.util.Vector _annotationElementList;
186
187   /**
188    * Field _label.
189    */
190   private java.lang.String _label;
191
192   /**
193    * Field _description.
194    */
195   private java.lang.String _description;
196
197   /**
198    * Field _thresholdLine.
199    */
200   private jalview.schemabinding.version2.ThresholdLine _thresholdLine;
201
202   // ----------------/
203   // - Constructors -/
204   // ----------------/
205
206   public Annotation()
207   {
208     super();
209     this._annotationElementList = new java.util.Vector();
210   }
211
212   // -----------/
213   // - Methods -/
214   // -----------/
215
216   /**
217    * 
218    * 
219    * @param vAnnotationElement
220    * @throws java.lang.IndexOutOfBoundsException
221    *           if the index given is outside the bounds of the collection
222    */
223   public void addAnnotationElement(
224           final jalview.schemabinding.version2.AnnotationElement vAnnotationElement)
225           throws java.lang.IndexOutOfBoundsException
226   {
227     this._annotationElementList.addElement(vAnnotationElement);
228   }
229
230   /**
231    * 
232    * 
233    * @param index
234    * @param vAnnotationElement
235    * @throws java.lang.IndexOutOfBoundsException
236    *           if the index given is outside the bounds of the collection
237    */
238   public void addAnnotationElement(
239           final int index,
240           final jalview.schemabinding.version2.AnnotationElement vAnnotationElement)
241           throws java.lang.IndexOutOfBoundsException
242   {
243     this._annotationElementList.add(index, vAnnotationElement);
244   }
245
246   /**
247      */
248   public void deleteAutoCalculated()
249   {
250     this._has_autoCalculated = false;
251   }
252
253   /**
254      */
255   public void deleteBelowAlignment()
256   {
257     this._has_belowAlignment = false;
258   }
259
260   /**
261      */
262   public void deleteCentreColLabels()
263   {
264     this._has_centreColLabels = false;
265   }
266
267   /**
268      */
269   public void deleteGraph()
270   {
271     this._has_graph = false;
272   }
273
274   /**
275      */
276   public void deleteGraphColour()
277   {
278     this._has_graphColour = false;
279   }
280
281   /**
282      */
283   public void deleteGraphGroup()
284   {
285     this._has_graphGroup = false;
286   }
287
288   /**
289      */
290   public void deleteGraphHeight()
291   {
292     this._has_graphHeight = false;
293   }
294
295   /**
296      */
297   public void deleteGraphType()
298   {
299     this._has_graphType = false;
300   }
301
302   /**
303      */
304   public void deleteScaleColLabels()
305   {
306     this._has_scaleColLabels = false;
307   }
308
309   /**
310      */
311   public void deleteScore()
312   {
313     this._has_score = false;
314   }
315
316   /**
317      */
318   public void deleteScoreOnly()
319   {
320     this._has_scoreOnly = false;
321   }
322
323   /**
324      */
325   public void deleteShowAllColLabels()
326   {
327     this._has_showAllColLabels = false;
328   }
329
330   /**
331      */
332   public void deleteVisible()
333   {
334     this._has_visible = false;
335   }
336
337   /**
338    * Method enumerateAnnotationElement.
339    * 
340    * @return an Enumeration over all
341    *         jalview.schemabinding.version2.AnnotationElement elements
342    */
343   public java.util.Enumeration enumerateAnnotationElement()
344   {
345     return this._annotationElementList.elements();
346   }
347
348   /**
349    * Method getAnnotationElement.
350    * 
351    * @param index
352    * @throws java.lang.IndexOutOfBoundsException
353    *           if the index given is outside the bounds of the collection
354    * @return the value of the jalview.schemabinding.version2.AnnotationElement
355    *         at the given index
356    */
357   public jalview.schemabinding.version2.AnnotationElement getAnnotationElement(
358           final int index) throws java.lang.IndexOutOfBoundsException
359   {
360     // check bounds for index
361     if (index < 0 || index >= this._annotationElementList.size())
362     {
363       throw new IndexOutOfBoundsException(
364               "getAnnotationElement: Index value '" + index
365                       + "' not in range [0.."
366                       + (this._annotationElementList.size() - 1) + "]");
367     }
368
369     return (jalview.schemabinding.version2.AnnotationElement) _annotationElementList
370             .get(index);
371   }
372
373   /**
374    * Method getAnnotationElement.Returns the contents of the collection in an
375    * Array.
376    * <p>
377    * Note: Just in case the collection contents are changing in another thread,
378    * we pass a 0-length Array of the correct type into the API call. This way we
379    * <i>know</i> that the Array returned is of exactly the correct length.
380    * 
381    * @return this collection as an Array
382    */
383   public jalview.schemabinding.version2.AnnotationElement[] getAnnotationElement()
384   {
385     jalview.schemabinding.version2.AnnotationElement[] array = new jalview.schemabinding.version2.AnnotationElement[0];
386     return (jalview.schemabinding.version2.AnnotationElement[]) this._annotationElementList
387             .toArray(array);
388   }
389
390   /**
391    * Method getAnnotationElementCount.
392    * 
393    * @return the size of this collection
394    */
395   public int getAnnotationElementCount()
396   {
397     return this._annotationElementList.size();
398   }
399
400   /**
401    * Returns the value of field 'autoCalculated'. The field 'autoCalculated' has
402    * the following description: is an autocalculated annotation row
403    * 
404    * @return the value of field 'AutoCalculated'.
405    */
406   public boolean getAutoCalculated()
407   {
408     return this._autoCalculated;
409   }
410
411   /**
412    * Returns the value of field 'belowAlignment'. The field 'belowAlignment' has
413    * the following description: is to be shown below the alignment - introduced
414    * in Jalview 2.8 for visualizing T-COFFEE alignment scores
415    * 
416    * @return the value of field 'BelowAlignment'.
417    */
418   public boolean getBelowAlignment()
419   {
420     return this._belowAlignment;
421   }
422
423   /**
424    * Returns the value of field 'calcId'. The field 'calcId' has the following
425    * description: Optional string identifier used to group sets of annotation
426    * produced by a particular calculation. Values are opaque strings but have
427    * semantic meaning to Jalview's renderer, data importer and calculation
428    * system.
429    * 
430    * @return the value of field 'CalcId'.
431    */
432   public java.lang.String getCalcId()
433   {
434     return this._calcId;
435   }
436
437   /**
438    * Returns the value of field 'centreColLabels'.
439    * 
440    * @return the value of field 'CentreColLabels'.
441    */
442   public boolean getCentreColLabels()
443   {
444     return this._centreColLabels;
445   }
446
447   /**
448    * Returns the value of field 'description'.
449    * 
450    * @return the value of field 'Description'.
451    */
452   public java.lang.String getDescription()
453   {
454     return this._description;
455   }
456
457   /**
458    * Returns the value of field 'graph'.
459    * 
460    * @return the value of field 'Graph'.
461    */
462   public boolean getGraph()
463   {
464     return this._graph;
465   }
466
467   /**
468    * Returns the value of field 'graphColour'.
469    * 
470    * @return the value of field 'GraphColour'.
471    */
472   public int getGraphColour()
473   {
474     return this._graphColour;
475   }
476
477   /**
478    * Returns the value of field 'graphGroup'.
479    * 
480    * @return the value of field 'GraphGroup'.
481    */
482   public int getGraphGroup()
483   {
484     return this._graphGroup;
485   }
486
487   /**
488    * Returns the value of field 'graphHeight'. The field 'graphHeight' has the
489    * following description: height in pixels for the graph if this is a
490    * graph-type annotation.
491    * 
492    * @return the value of field 'GraphHeight'.
493    */
494   public int getGraphHeight()
495   {
496     return this._graphHeight;
497   }
498
499   /**
500    * Returns the value of field 'graphType'.
501    * 
502    * @return the value of field 'GraphType'.
503    */
504   public int getGraphType()
505   {
506     return this._graphType;
507   }
508
509   /**
510    * Returns the value of field 'groupRef'.
511    * 
512    * @return the value of field 'GroupRef'.
513    */
514   public java.lang.String getGroupRef()
515   {
516     return this._groupRef;
517   }
518
519   /**
520    * Returns the value of field 'id'.
521    * 
522    * @return the value of field 'Id'.
523    */
524   public java.lang.String getId()
525   {
526     return this._id;
527   }
528
529   /**
530    * Returns the value of field 'label'.
531    * 
532    * @return the value of field 'Label'.
533    */
534   public java.lang.String getLabel()
535   {
536     return this._label;
537   }
538
539   /**
540    * Returns the value of field 'scaleColLabels'.
541    * 
542    * @return the value of field 'ScaleColLabels'.
543    */
544   public boolean getScaleColLabels()
545   {
546     return this._scaleColLabels;
547   }
548
549   /**
550    * Returns the value of field 'score'.
551    * 
552    * @return the value of field 'Score'.
553    */
554   public double getScore()
555   {
556     return this._score;
557   }
558
559   /**
560    * Returns the value of field 'scoreOnly'.
561    * 
562    * @return the value of field 'ScoreOnly'.
563    */
564   public boolean getScoreOnly()
565   {
566     return this._scoreOnly;
567   }
568
569   /**
570    * Returns the value of field 'sequenceRef'.
571    * 
572    * @return the value of field 'SequenceRef'.
573    */
574   public java.lang.String getSequenceRef()
575   {
576     return this._sequenceRef;
577   }
578
579   /**
580    * Returns the value of field 'showAllColLabels'.
581    * 
582    * @return the value of field 'ShowAllColLabels'.
583    */
584   public boolean getShowAllColLabels()
585   {
586     return this._showAllColLabels;
587   }
588
589   /**
590    * Returns the value of field 'thresholdLine'.
591    * 
592    * @return the value of field 'ThresholdLine'.
593    */
594   public jalview.schemabinding.version2.ThresholdLine getThresholdLine()
595   {
596     return this._thresholdLine;
597   }
598
599   /**
600    * Returns the value of field 'visible'.
601    * 
602    * @return the value of field 'Visible'.
603    */
604   public boolean getVisible()
605   {
606     return this._visible;
607   }
608
609   /**
610    * Method hasAutoCalculated.
611    * 
612    * @return true if at least one AutoCalculated has been added
613    */
614   public boolean hasAutoCalculated()
615   {
616     return this._has_autoCalculated;
617   }
618
619   /**
620    * Method hasBelowAlignment.
621    * 
622    * @return true if at least one BelowAlignment has been added
623    */
624   public boolean hasBelowAlignment()
625   {
626     return this._has_belowAlignment;
627   }
628
629   /**
630    * Method hasCentreColLabels.
631    * 
632    * @return true if at least one CentreColLabels has been added
633    */
634   public boolean hasCentreColLabels()
635   {
636     return this._has_centreColLabels;
637   }
638
639   /**
640    * Method hasGraph.
641    * 
642    * @return true if at least one Graph has been added
643    */
644   public boolean hasGraph()
645   {
646     return this._has_graph;
647   }
648
649   /**
650    * Method hasGraphColour.
651    * 
652    * @return true if at least one GraphColour has been added
653    */
654   public boolean hasGraphColour()
655   {
656     return this._has_graphColour;
657   }
658
659   /**
660    * Method hasGraphGroup.
661    * 
662    * @return true if at least one GraphGroup has been added
663    */
664   public boolean hasGraphGroup()
665   {
666     return this._has_graphGroup;
667   }
668
669   /**
670    * Method hasGraphHeight.
671    * 
672    * @return true if at least one GraphHeight has been added
673    */
674   public boolean hasGraphHeight()
675   {
676     return this._has_graphHeight;
677   }
678
679   /**
680    * Method hasGraphType.
681    * 
682    * @return true if at least one GraphType has been added
683    */
684   public boolean hasGraphType()
685   {
686     return this._has_graphType;
687   }
688
689   /**
690    * Method hasScaleColLabels.
691    * 
692    * @return true if at least one ScaleColLabels has been added
693    */
694   public boolean hasScaleColLabels()
695   {
696     return this._has_scaleColLabels;
697   }
698
699   /**
700    * Method hasScore.
701    * 
702    * @return true if at least one Score has been added
703    */
704   public boolean hasScore()
705   {
706     return this._has_score;
707   }
708
709   /**
710    * Method hasScoreOnly.
711    * 
712    * @return true if at least one ScoreOnly has been added
713    */
714   public boolean hasScoreOnly()
715   {
716     return this._has_scoreOnly;
717   }
718
719   /**
720    * Method hasShowAllColLabels.
721    * 
722    * @return true if at least one ShowAllColLabels has been added
723    */
724   public boolean hasShowAllColLabels()
725   {
726     return this._has_showAllColLabels;
727   }
728
729   /**
730    * Method hasVisible.
731    * 
732    * @return true if at least one Visible has been added
733    */
734   public boolean hasVisible()
735   {
736     return this._has_visible;
737   }
738
739   /**
740    * Returns the value of field 'autoCalculated'. The field 'autoCalculated' has
741    * the following description: is an autocalculated annotation row
742    * 
743    * @return the value of field 'AutoCalculated'.
744    */
745   public boolean isAutoCalculated()
746   {
747     return this._autoCalculated;
748   }
749
750   /**
751    * Returns the value of field 'belowAlignment'. The field 'belowAlignment' has
752    * the following description: is to be shown below the alignment - introduced
753    * in Jalview 2.8 for visualizing T-COFFEE alignment scores
754    * 
755    * @return the value of field 'BelowAlignment'.
756    */
757   public boolean isBelowAlignment()
758   {
759     return this._belowAlignment;
760   }
761
762   /**
763    * Returns the value of field 'centreColLabels'.
764    * 
765    * @return the value of field 'CentreColLabels'.
766    */
767   public boolean isCentreColLabels()
768   {
769     return this._centreColLabels;
770   }
771
772   /**
773    * Returns the value of field 'graph'.
774    * 
775    * @return the value of field 'Graph'.
776    */
777   public boolean isGraph()
778   {
779     return this._graph;
780   }
781
782   /**
783    * Returns the value of field 'scaleColLabels'.
784    * 
785    * @return the value of field 'ScaleColLabels'.
786    */
787   public boolean isScaleColLabels()
788   {
789     return this._scaleColLabels;
790   }
791
792   /**
793    * Returns the value of field 'scoreOnly'.
794    * 
795    * @return the value of field 'ScoreOnly'.
796    */
797   public boolean isScoreOnly()
798   {
799     return this._scoreOnly;
800   }
801
802   /**
803    * Returns the value of field 'showAllColLabels'.
804    * 
805    * @return the value of field 'ShowAllColLabels'.
806    */
807   public boolean isShowAllColLabels()
808   {
809     return this._showAllColLabels;
810   }
811
812   /**
813    * Method isValid.
814    * 
815    * @return true if this object is valid according to the schema
816    */
817   public boolean isValid()
818   {
819     try
820     {
821       validate();
822     } catch (org.exolab.castor.xml.ValidationException vex)
823     {
824       return false;
825     }
826     return true;
827   }
828
829   /**
830    * Returns the value of field 'visible'.
831    * 
832    * @return the value of field 'Visible'.
833    */
834   public boolean isVisible()
835   {
836     return this._visible;
837   }
838
839   /**
840    * 
841    * 
842    * @param out
843    * @throws org.exolab.castor.xml.MarshalException
844    *           if object is null or if any SAXException is thrown during
845    *           marshaling
846    * @throws org.exolab.castor.xml.ValidationException
847    *           if this object is an invalid instance according to the schema
848    */
849   public void marshal(final java.io.Writer out)
850           throws org.exolab.castor.xml.MarshalException,
851           org.exolab.castor.xml.ValidationException
852   {
853     Marshaller.marshal(this, out);
854   }
855
856   /**
857    * 
858    * 
859    * @param handler
860    * @throws java.io.IOException
861    *           if an IOException occurs during marshaling
862    * @throws org.exolab.castor.xml.ValidationException
863    *           if this object is an invalid instance according to the schema
864    * @throws org.exolab.castor.xml.MarshalException
865    *           if object is null or if any SAXException is thrown during
866    *           marshaling
867    */
868   public void marshal(final org.xml.sax.ContentHandler handler)
869           throws java.io.IOException,
870           org.exolab.castor.xml.MarshalException,
871           org.exolab.castor.xml.ValidationException
872   {
873     Marshaller.marshal(this, handler);
874   }
875
876   /**
877      */
878   public void removeAllAnnotationElement()
879   {
880     this._annotationElementList.clear();
881   }
882
883   /**
884    * Method removeAnnotationElement.
885    * 
886    * @param vAnnotationElement
887    * @return true if the object was removed from the collection.
888    */
889   public boolean removeAnnotationElement(
890           final jalview.schemabinding.version2.AnnotationElement vAnnotationElement)
891   {
892     boolean removed = _annotationElementList.remove(vAnnotationElement);
893     return removed;
894   }
895
896   /**
897    * Method removeAnnotationElementAt.
898    * 
899    * @param index
900    * @return the element removed from the collection
901    */
902   public jalview.schemabinding.version2.AnnotationElement removeAnnotationElementAt(
903           final int index)
904   {
905     java.lang.Object obj = this._annotationElementList.remove(index);
906     return (jalview.schemabinding.version2.AnnotationElement) obj;
907   }
908
909   /**
910    * 
911    * 
912    * @param index
913    * @param vAnnotationElement
914    * @throws java.lang.IndexOutOfBoundsException
915    *           if the index given is outside the bounds of the collection
916    */
917   public void setAnnotationElement(
918           final int index,
919           final jalview.schemabinding.version2.AnnotationElement vAnnotationElement)
920           throws java.lang.IndexOutOfBoundsException
921   {
922     // check bounds for index
923     if (index < 0 || index >= this._annotationElementList.size())
924     {
925       throw new IndexOutOfBoundsException(
926               "setAnnotationElement: Index value '" + index
927                       + "' not in range [0.."
928                       + (this._annotationElementList.size() - 1) + "]");
929     }
930
931     this._annotationElementList.set(index, vAnnotationElement);
932   }
933
934   /**
935    * 
936    * 
937    * @param vAnnotationElementArray
938    */
939   public void setAnnotationElement(
940           final jalview.schemabinding.version2.AnnotationElement[] vAnnotationElementArray)
941   {
942     // -- copy array
943     _annotationElementList.clear();
944
945     for (int i = 0; i < vAnnotationElementArray.length; i++)
946     {
947       this._annotationElementList.add(vAnnotationElementArray[i]);
948     }
949   }
950
951   /**
952    * Sets the value of field 'autoCalculated'. The field 'autoCalculated' has
953    * the following description: is an autocalculated annotation row
954    * 
955    * @param autoCalculated
956    *          the value of field 'autoCalculated'.
957    */
958   public void setAutoCalculated(final boolean autoCalculated)
959   {
960     this._autoCalculated = autoCalculated;
961     this._has_autoCalculated = true;
962   }
963
964   /**
965    * Sets the value of field 'belowAlignment'. The field 'belowAlignment' has
966    * the following description: is to be shown below the alignment - introduced
967    * in Jalview 2.8 for visualizing T-COFFEE alignment scores
968    * 
969    * @param belowAlignment
970    *          the value of field 'belowAlignment'.
971    */
972   public void setBelowAlignment(final boolean belowAlignment)
973   {
974     this._belowAlignment = belowAlignment;
975     this._has_belowAlignment = true;
976   }
977
978   /**
979    * Sets the value of field 'calcId'. The field 'calcId' has the following
980    * description: Optional string identifier used to group sets of annotation
981    * produced by a particular calculation. Values are opaque strings but have
982    * semantic meaning to Jalview's renderer, data importer and calculation
983    * system.
984    * 
985    * @param calcId
986    *          the value of field 'calcId'.
987    */
988   public void setCalcId(final java.lang.String calcId)
989   {
990     this._calcId = calcId;
991   }
992
993   /**
994    * Sets the value of field 'centreColLabels'.
995    * 
996    * @param centreColLabels
997    *          the value of field 'centreColLabels'.
998    */
999   public void setCentreColLabels(final boolean centreColLabels)
1000   {
1001     this._centreColLabels = centreColLabels;
1002     this._has_centreColLabels = true;
1003   }
1004
1005   /**
1006    * Sets the value of field 'description'.
1007    * 
1008    * @param description
1009    *          the value of field 'description'.
1010    */
1011   public void setDescription(final java.lang.String description)
1012   {
1013     this._description = description;
1014   }
1015
1016   /**
1017    * Sets the value of field 'graph'.
1018    * 
1019    * @param graph
1020    *          the value of field 'graph'.
1021    */
1022   public void setGraph(final boolean graph)
1023   {
1024     this._graph = graph;
1025     this._has_graph = true;
1026   }
1027
1028   /**
1029    * Sets the value of field 'graphColour'.
1030    * 
1031    * @param graphColour
1032    *          the value of field 'graphColour'.
1033    */
1034   public void setGraphColour(final int graphColour)
1035   {
1036     this._graphColour = graphColour;
1037     this._has_graphColour = true;
1038   }
1039
1040   /**
1041    * Sets the value of field 'graphGroup'.
1042    * 
1043    * @param graphGroup
1044    *          the value of field 'graphGroup'.
1045    */
1046   public void setGraphGroup(final int graphGroup)
1047   {
1048     this._graphGroup = graphGroup;
1049     this._has_graphGroup = true;
1050   }
1051
1052   /**
1053    * Sets the value of field 'graphHeight'. The field 'graphHeight' has the
1054    * following description: height in pixels for the graph if this is a
1055    * graph-type annotation.
1056    * 
1057    * @param graphHeight
1058    *          the value of field 'graphHeight'.
1059    */
1060   public void setGraphHeight(final int graphHeight)
1061   {
1062     this._graphHeight = graphHeight;
1063     this._has_graphHeight = true;
1064   }
1065
1066   /**
1067    * Sets the value of field 'graphType'.
1068    * 
1069    * @param graphType
1070    *          the value of field 'graphType'.
1071    */
1072   public void setGraphType(final int graphType)
1073   {
1074     this._graphType = graphType;
1075     this._has_graphType = true;
1076   }
1077
1078   /**
1079    * Sets the value of field 'groupRef'.
1080    * 
1081    * @param groupRef
1082    *          the value of field 'groupRef'.
1083    */
1084   public void setGroupRef(final java.lang.String groupRef)
1085   {
1086     this._groupRef = groupRef;
1087   }
1088
1089   /**
1090    * Sets the value of field 'id'.
1091    * 
1092    * @param id
1093    *          the value of field 'id'.
1094    */
1095   public void setId(final java.lang.String id)
1096   {
1097     this._id = id;
1098   }
1099
1100   /**
1101    * Sets the value of field 'label'.
1102    * 
1103    * @param label
1104    *          the value of field 'label'.
1105    */
1106   public void setLabel(final java.lang.String label)
1107   {
1108     this._label = label;
1109   }
1110
1111   /**
1112    * Sets the value of field 'scaleColLabels'.
1113    * 
1114    * @param scaleColLabels
1115    *          the value of field 'scaleColLabels'.
1116    */
1117   public void setScaleColLabels(final boolean scaleColLabels)
1118   {
1119     this._scaleColLabels = scaleColLabels;
1120     this._has_scaleColLabels = true;
1121   }
1122
1123   /**
1124    * Sets the value of field 'score'.
1125    * 
1126    * @param score
1127    *          the value of field 'score'.
1128    */
1129   public void setScore(final double score)
1130   {
1131     this._score = score;
1132     this._has_score = true;
1133   }
1134
1135   /**
1136    * Sets the value of field 'scoreOnly'.
1137    * 
1138    * @param scoreOnly
1139    *          the value of field 'scoreOnly'.
1140    */
1141   public void setScoreOnly(final boolean scoreOnly)
1142   {
1143     this._scoreOnly = scoreOnly;
1144     this._has_scoreOnly = true;
1145   }
1146
1147   /**
1148    * Sets the value of field 'sequenceRef'.
1149    * 
1150    * @param sequenceRef
1151    *          the value of field 'sequenceRef'.
1152    */
1153   public void setSequenceRef(final java.lang.String sequenceRef)
1154   {
1155     this._sequenceRef = sequenceRef;
1156   }
1157
1158   /**
1159    * Sets the value of field 'showAllColLabels'.
1160    * 
1161    * @param showAllColLabels
1162    *          the value of field 'showAllColLabels'
1163    */
1164   public void setShowAllColLabels(final boolean showAllColLabels)
1165   {
1166     this._showAllColLabels = showAllColLabels;
1167     this._has_showAllColLabels = true;
1168   }
1169
1170   /**
1171    * Sets the value of field 'thresholdLine'.
1172    * 
1173    * @param thresholdLine
1174    *          the value of field 'thresholdLine'.
1175    */
1176   public void setThresholdLine(
1177           final jalview.schemabinding.version2.ThresholdLine thresholdLine)
1178   {
1179     this._thresholdLine = thresholdLine;
1180   }
1181
1182   /**
1183    * Sets the value of field 'visible'.
1184    * 
1185    * @param visible
1186    *          the value of field 'visible'.
1187    */
1188   public void setVisible(final boolean visible)
1189   {
1190     this._visible = visible;
1191     this._has_visible = true;
1192   }
1193
1194   /**
1195    * Method unmarshal.
1196    * 
1197    * @param reader
1198    * @throws org.exolab.castor.xml.MarshalException
1199    *           if object is null or if any SAXException is thrown during
1200    *           marshaling
1201    * @throws org.exolab.castor.xml.ValidationException
1202    *           if this object is an invalid instance according to the schema
1203    * @return the unmarshaled jalview.schemabinding.version2.Annotation
1204    */
1205   public static jalview.schemabinding.version2.Annotation unmarshal(
1206           final java.io.Reader reader)
1207           throws org.exolab.castor.xml.MarshalException,
1208           org.exolab.castor.xml.ValidationException
1209   {
1210     return (jalview.schemabinding.version2.Annotation) Unmarshaller
1211             .unmarshal(jalview.schemabinding.version2.Annotation.class,
1212                     reader);
1213   }
1214
1215   /**
1216    * 
1217    * 
1218    * @throws org.exolab.castor.xml.ValidationException
1219    *           if this object is an invalid instance according to the schema
1220    */
1221   public void validate() throws org.exolab.castor.xml.ValidationException
1222   {
1223     org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
1224     validator.validate(this);
1225   }
1226
1227 }