update author list in license for (JAL-826)
[jalview.git] / src / jalview / schemabinding / version2 / StructureState.java
1 /*******************************************************************************
2  * Jalview - A Sequence Alignment Editor and Viewer (Version 2.7)
3  * Copyright (C) 2011 J Procter, AM Waterhouse, J Engelhardt, LM Lui, G Barton, M Clamp, S Searle
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 of the License, or (at your option) any later version.
10  *
11  * Jalview is distributed in the hope that it will be useful, but 
12  * WITHOUT ANY WARRANTY; without even the implied warranty 
13  * of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
14  * PURPOSE.  See the GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License along with Jalview.  If not, see <http://www.gnu.org/licenses/>.
17  *******************************************************************************/
18 /*
19  * This class was automatically generated with 
20  * <a href="http://www.castor.org">Castor 1.1</a>, using an XML
21  * Schema.
22  * $Id$
23  */
24
25 package jalview.schemabinding.version2;
26
27   //---------------------------------/
28  //- Imported classes and packages -/
29 //---------------------------------/
30
31 import org.exolab.castor.xml.Marshaller;
32 import org.exolab.castor.xml.Unmarshaller;
33
34 /**
35  * Class StructureState.
36  * 
37  * @version $Revision$ $Date$
38  */
39 public class StructureState implements java.io.Serializable {
40
41
42       //--------------------------/
43      //- Class/Member Variables -/
44     //--------------------------/
45
46     /**
47      * internal content storage
48      */
49     private java.lang.String _content = "";
50
51     /**
52      * Field _visible.
53      */
54     private boolean _visible;
55
56     /**
57      * keeps track of state for field: _visible
58      */
59     private boolean _has_visible;
60
61     /**
62      * additional identifier which properly disambiguates
63      *  the structure view from any other view with the same
64      * attributes. This is not an ID,
65      *  because it is possible to have many references to the same
66      * physical structure view
67      *  from different sequences in an alignment. A structureState
68      * element citing the same
69      *  viewId will appear for each instance.
70      */
71     private java.lang.String _viewId;
72
73     /**
74      * Flag set if the alignment panel containing this JSeq should
75      * be included in those used to perform a structure
76      * superposition (since Jalview 2.7).
77      *  
78      */
79     private boolean _alignwithAlignPanel = true;
80
81     /**
82      * keeps track of state for field: _alignwithAlignPanel
83      */
84     private boolean _has_alignwithAlignPanel;
85
86     /**
87      * Flag set if the alignment panel containing this JSeq should
88      * be included in those used to colour its associated sequences
89      * in this structureState(since Jalview 2.7).
90      *  
91      */
92     private boolean _colourwithAlignPanel = false;
93
94     /**
95      * keeps track of state for field: _colourwithAlignPanel
96      */
97     private boolean _has_colourwithAlignPanel;
98
99     /**
100      * Flag set if the structure display is coloured by the Jmol
101      * state, rather than by one or more linked alignment views.
102      *  
103      */
104     private boolean _colourByJmol = true;
105
106     /**
107      * keeps track of state for field: _colourByJmol
108      */
109     private boolean _has_colourByJmol;
110
111     /**
112      * Field _width.
113      */
114     private int _width;
115
116     /**
117      * keeps track of state for field: _width
118      */
119     private boolean _has_width;
120
121     /**
122      * Field _height.
123      */
124     private int _height;
125
126     /**
127      * keeps track of state for field: _height
128      */
129     private boolean _has_height;
130
131     /**
132      * Field _xpos.
133      */
134     private int _xpos;
135
136     /**
137      * keeps track of state for field: _xpos
138      */
139     private boolean _has_xpos;
140
141     /**
142      * Field _ypos.
143      */
144     private int _ypos;
145
146     /**
147      * keeps track of state for field: _ypos
148      */
149     private boolean _has_ypos;
150
151
152       //----------------/
153      //- Constructors -/
154     //----------------/
155
156     public StructureState() {
157         super();
158         setContent("");
159     }
160
161
162       //-----------/
163      //- Methods -/
164     //-----------/
165
166     /**
167      */
168     public void deleteAlignwithAlignPanel(
169     ) {
170         this._has_alignwithAlignPanel= false;
171     }
172
173     /**
174      */
175     public void deleteColourByJmol(
176     ) {
177         this._has_colourByJmol= false;
178     }
179
180     /**
181      */
182     public void deleteColourwithAlignPanel(
183     ) {
184         this._has_colourwithAlignPanel= false;
185     }
186
187     /**
188      */
189     public void deleteHeight(
190     ) {
191         this._has_height= false;
192     }
193
194     /**
195      */
196     public void deleteVisible(
197     ) {
198         this._has_visible= false;
199     }
200
201     /**
202      */
203     public void deleteWidth(
204     ) {
205         this._has_width= false;
206     }
207
208     /**
209      */
210     public void deleteXpos(
211     ) {
212         this._has_xpos= false;
213     }
214
215     /**
216      */
217     public void deleteYpos(
218     ) {
219         this._has_ypos= false;
220     }
221
222     /**
223      * Returns the value of field 'alignwithAlignPanel'. The field
224      * 'alignwithAlignPanel' has the following description: Flag
225      * set if the alignment panel containing this JSeq should be
226      * included in those used to perform a structure superposition
227      * (since Jalview 2.7).
228      *  
229      * 
230      * @return the value of field 'AlignwithAlignPanel'.
231      */
232     public boolean getAlignwithAlignPanel(
233     ) {
234         return this._alignwithAlignPanel;
235     }
236
237     /**
238      * Returns the value of field 'colourByJmol'. The field
239      * 'colourByJmol' has the following description: Flag set if
240      * the structure display is coloured by the Jmol state, rather
241      * than by one or more linked alignment views.
242      *  
243      * 
244      * @return the value of field 'ColourByJmol'.
245      */
246     public boolean getColourByJmol(
247     ) {
248         return this._colourByJmol;
249     }
250
251     /**
252      * Returns the value of field 'colourwithAlignPanel'. The field
253      * 'colourwithAlignPanel' has the following description: Flag
254      * set if the alignment panel containing this JSeq should be
255      * included in those used to colour its associated sequences in
256      * this structureState(since Jalview 2.7).
257      *  
258      * 
259      * @return the value of field 'ColourwithAlignPanel'.
260      */
261     public boolean getColourwithAlignPanel(
262     ) {
263         return this._colourwithAlignPanel;
264     }
265
266     /**
267      * Returns the value of field 'content'. The field 'content'
268      * has the following description: internal content storage
269      * 
270      * @return the value of field 'Content'.
271      */
272     public java.lang.String getContent(
273     ) {
274         return this._content;
275     }
276
277     /**
278      * Returns the value of field 'height'.
279      * 
280      * @return the value of field 'Height'.
281      */
282     public int getHeight(
283     ) {
284         return this._height;
285     }
286
287     /**
288      * Returns the value of field 'viewId'. The field 'viewId' has
289      * the following description: additional identifier which
290      * properly disambiguates
291      *  the structure view from any other view with the same
292      * attributes. This is not an ID,
293      *  because it is possible to have many references to the same
294      * physical structure view
295      *  from different sequences in an alignment. A structureState
296      * element citing the same
297      *  viewId will appear for each instance.
298      * 
299      * @return the value of field 'ViewId'.
300      */
301     public java.lang.String getViewId(
302     ) {
303         return this._viewId;
304     }
305
306     /**
307      * Returns the value of field 'visible'.
308      * 
309      * @return the value of field 'Visible'.
310      */
311     public boolean getVisible(
312     ) {
313         return this._visible;
314     }
315
316     /**
317      * Returns the value of field 'width'.
318      * 
319      * @return the value of field 'Width'.
320      */
321     public int getWidth(
322     ) {
323         return this._width;
324     }
325
326     /**
327      * Returns the value of field 'xpos'.
328      * 
329      * @return the value of field 'Xpos'.
330      */
331     public int getXpos(
332     ) {
333         return this._xpos;
334     }
335
336     /**
337      * Returns the value of field 'ypos'.
338      * 
339      * @return the value of field 'Ypos'.
340      */
341     public int getYpos(
342     ) {
343         return this._ypos;
344     }
345
346     /**
347      * Method hasAlignwithAlignPanel.
348      * 
349      * @return true if at least one AlignwithAlignPanel has been
350      * added
351      */
352     public boolean hasAlignwithAlignPanel(
353     ) {
354         return this._has_alignwithAlignPanel;
355     }
356
357     /**
358      * Method hasColourByJmol.
359      * 
360      * @return true if at least one ColourByJmol has been added
361      */
362     public boolean hasColourByJmol(
363     ) {
364         return this._has_colourByJmol;
365     }
366
367     /**
368      * Method hasColourwithAlignPanel.
369      * 
370      * @return true if at least one ColourwithAlignPanel has been
371      * added
372      */
373     public boolean hasColourwithAlignPanel(
374     ) {
375         return this._has_colourwithAlignPanel;
376     }
377
378     /**
379      * Method hasHeight.
380      * 
381      * @return true if at least one Height has been added
382      */
383     public boolean hasHeight(
384     ) {
385         return this._has_height;
386     }
387
388     /**
389      * Method hasVisible.
390      * 
391      * @return true if at least one Visible has been added
392      */
393     public boolean hasVisible(
394     ) {
395         return this._has_visible;
396     }
397
398     /**
399      * Method hasWidth.
400      * 
401      * @return true if at least one Width has been added
402      */
403     public boolean hasWidth(
404     ) {
405         return this._has_width;
406     }
407
408     /**
409      * Method hasXpos.
410      * 
411      * @return true if at least one Xpos has been added
412      */
413     public boolean hasXpos(
414     ) {
415         return this._has_xpos;
416     }
417
418     /**
419      * Method hasYpos.
420      * 
421      * @return true if at least one Ypos has been added
422      */
423     public boolean hasYpos(
424     ) {
425         return this._has_ypos;
426     }
427
428     /**
429      * Returns the value of field 'alignwithAlignPanel'. The field
430      * 'alignwithAlignPanel' has the following description: Flag
431      * set if the alignment panel containing this JSeq should be
432      * included in those used to perform a structure superposition
433      * (since Jalview 2.7).
434      *  
435      * 
436      * @return the value of field 'AlignwithAlignPanel'.
437      */
438     public boolean isAlignwithAlignPanel(
439     ) {
440         return this._alignwithAlignPanel;
441     }
442
443     /**
444      * Returns the value of field 'colourByJmol'. The field
445      * 'colourByJmol' has the following description: Flag set if
446      * the structure display is coloured by the Jmol state, rather
447      * than by one or more linked alignment views.
448      *  
449      * 
450      * @return the value of field 'ColourByJmol'.
451      */
452     public boolean isColourByJmol(
453     ) {
454         return this._colourByJmol;
455     }
456
457     /**
458      * Returns the value of field 'colourwithAlignPanel'. The field
459      * 'colourwithAlignPanel' has the following description: Flag
460      * set if the alignment panel containing this JSeq should be
461      * included in those used to colour its associated sequences in
462      * this structureState(since Jalview 2.7).
463      *  
464      * 
465      * @return the value of field 'ColourwithAlignPanel'.
466      */
467     public boolean isColourwithAlignPanel(
468     ) {
469         return this._colourwithAlignPanel;
470     }
471
472     /**
473      * Method isValid.
474      * 
475      * @return true if this object is valid according to the schema
476      */
477     public boolean isValid(
478     ) {
479         try {
480             validate();
481         } catch (org.exolab.castor.xml.ValidationException vex) {
482             return false;
483         }
484         return true;
485     }
486
487     /**
488      * Returns the value of field 'visible'.
489      * 
490      * @return the value of field 'Visible'.
491      */
492     public boolean isVisible(
493     ) {
494         return this._visible;
495     }
496
497     /**
498      * 
499      * 
500      * @param out
501      * @throws org.exolab.castor.xml.MarshalException if object is
502      * null or if any SAXException is thrown during marshaling
503      * @throws org.exolab.castor.xml.ValidationException if this
504      * object is an invalid instance according to the schema
505      */
506     public void marshal(
507             final java.io.Writer out)
508     throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {
509         Marshaller.marshal(this, out);
510     }
511
512     /**
513      * 
514      * 
515      * @param handler
516      * @throws java.io.IOException if an IOException occurs during
517      * marshaling
518      * @throws org.exolab.castor.xml.ValidationException if this
519      * object is an invalid instance according to the schema
520      * @throws org.exolab.castor.xml.MarshalException if object is
521      * null or if any SAXException is thrown during marshaling
522      */
523     public void marshal(
524             final org.xml.sax.ContentHandler handler)
525     throws java.io.IOException, org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {
526         Marshaller.marshal(this, handler);
527     }
528
529     /**
530      * Sets the value of field 'alignwithAlignPanel'. The field
531      * 'alignwithAlignPanel' has the following description: Flag
532      * set if the alignment panel containing this JSeq should be
533      * included in those used to perform a structure superposition
534      * (since Jalview 2.7).
535      *  
536      * 
537      * @param alignwithAlignPanel the value of field
538      * 'alignwithAlignPanel'.
539      */
540     public void setAlignwithAlignPanel(
541             final boolean alignwithAlignPanel) {
542         this._alignwithAlignPanel = alignwithAlignPanel;
543         this._has_alignwithAlignPanel = true;
544     }
545
546     /**
547      * Sets the value of field 'colourByJmol'. The field
548      * 'colourByJmol' has the following description: Flag set if
549      * the structure display is coloured by the Jmol state, rather
550      * than by one or more linked alignment views.
551      *  
552      * 
553      * @param colourByJmol the value of field 'colourByJmol'.
554      */
555     public void setColourByJmol(
556             final boolean colourByJmol) {
557         this._colourByJmol = colourByJmol;
558         this._has_colourByJmol = true;
559     }
560
561     /**
562      * Sets the value of field 'colourwithAlignPanel'. The field
563      * 'colourwithAlignPanel' has the following description: Flag
564      * set if the alignment panel containing this JSeq should be
565      * included in those used to colour its associated sequences in
566      * this structureState(since Jalview 2.7).
567      *  
568      * 
569      * @param colourwithAlignPanel the value of field
570      * 'colourwithAlignPanel'.
571      */
572     public void setColourwithAlignPanel(
573             final boolean colourwithAlignPanel) {
574         this._colourwithAlignPanel = colourwithAlignPanel;
575         this._has_colourwithAlignPanel = true;
576     }
577
578     /**
579      * Sets the value of field 'content'. The field 'content' has
580      * the following description: internal content storage
581      * 
582      * @param content the value of field 'content'.
583      */
584     public void setContent(
585             final java.lang.String content) {
586         this._content = content;
587     }
588
589     /**
590      * Sets the value of field 'height'.
591      * 
592      * @param height the value of field 'height'.
593      */
594     public void setHeight(
595             final int height) {
596         this._height = height;
597         this._has_height = true;
598     }
599
600     /**
601      * Sets the value of field 'viewId'. The field 'viewId' has the
602      * following description: additional identifier which properly
603      * disambiguates
604      *  the structure view from any other view with the same
605      * attributes. This is not an ID,
606      *  because it is possible to have many references to the same
607      * physical structure view
608      *  from different sequences in an alignment. A structureState
609      * element citing the same
610      *  viewId will appear for each instance.
611      * 
612      * @param viewId the value of field 'viewId'.
613      */
614     public void setViewId(
615             final java.lang.String viewId) {
616         this._viewId = viewId;
617     }
618
619     /**
620      * Sets the value of field 'visible'.
621      * 
622      * @param visible the value of field 'visible'.
623      */
624     public void setVisible(
625             final boolean visible) {
626         this._visible = visible;
627         this._has_visible = true;
628     }
629
630     /**
631      * Sets the value of field 'width'.
632      * 
633      * @param width the value of field 'width'.
634      */
635     public void setWidth(
636             final int width) {
637         this._width = width;
638         this._has_width = true;
639     }
640
641     /**
642      * Sets the value of field 'xpos'.
643      * 
644      * @param xpos the value of field 'xpos'.
645      */
646     public void setXpos(
647             final int xpos) {
648         this._xpos = xpos;
649         this._has_xpos = true;
650     }
651
652     /**
653      * Sets the value of field 'ypos'.
654      * 
655      * @param ypos the value of field 'ypos'.
656      */
657     public void setYpos(
658             final int ypos) {
659         this._ypos = ypos;
660         this._has_ypos = true;
661     }
662
663     /**
664      * Method unmarshal.
665      * 
666      * @param reader
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      * @return the unmarshaled
672      * jalview.schemabinding.version2.StructureState
673      */
674     public static jalview.schemabinding.version2.StructureState unmarshal(
675             final java.io.Reader reader)
676     throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {
677         return (jalview.schemabinding.version2.StructureState) Unmarshaller.unmarshal(jalview.schemabinding.version2.StructureState.class, reader);
678     }
679
680     /**
681      * 
682      * 
683      * @throws org.exolab.castor.xml.ValidationException if this
684      * object is an invalid instance according to the schema
685      */
686     public void validate(
687     )
688     throws org.exolab.castor.xml.ValidationException {
689         org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
690         validator.validate(this);
691     }
692
693 }