2 * This class was automatically generated with
3 * <a href="http://www.castor.org">Castor 1.1</a>, using an XML
8 package jalview.schemabinding.version2;
10 //---------------------------------/
11 //- Imported classes and packages -/
12 //---------------------------------/
14 import org.exolab.castor.xml.Marshaller;
15 import org.exolab.castor.xml.Unmarshaller;
18 * Class StructureState.
20 * @version $Revision$ $Date$
22 public class StructureState implements java.io.Serializable
25 // --------------------------/
26 // - Class/Member Variables -/
27 // --------------------------/
30 * internal content storage
32 private java.lang.String _content = "";
37 private boolean _visible;
40 * keeps track of state for field: _visible
42 private boolean _has_visible;
45 * additional identifier which properly disambiguates the structure view from
46 * any other view with the same attributes. This is not an ID, because it is
47 * possible to have many references to the same physical structure view from
48 * different sequences in an alignment. A structureState element citing the
49 * same viewId will appear for each instance.
52 private java.lang.String _viewId;
55 * Flag set if the alignment panel containing this JSeq should be included in
56 * those used to perform a structure superposition (since Jalview 2.7).
59 private boolean _alignwithAlignPanel = true;
62 * keeps track of state for field: _alignwithAlignPanel
64 private boolean _has_alignwithAlignPanel;
67 * Flag set if the alignment panel containing this JSeq should be included in
68 * those used to colour its associated sequences in this structureState(since
72 private boolean _colourwithAlignPanel = false;
75 * keeps track of state for field: _colourwithAlignPanel
77 private boolean _has_colourwithAlignPanel;
80 * Flag set if the structure display is coloured by the Jmol state, rather
81 * than by one or more linked alignment views.
84 private boolean _colourByJmol = true;
87 * keeps track of state for field: _colourByJmol
89 private boolean _has_colourByJmol;
97 * keeps track of state for field: _width
99 private boolean _has_width;
107 * keeps track of state for field: _height
109 private boolean _has_height;
117 * keeps track of state for field: _xpos
119 private boolean _has_xpos;
127 * keeps track of state for field: _ypos
129 private boolean _has_ypos;
135 public StructureState()
147 public void deleteAlignwithAlignPanel()
149 this._has_alignwithAlignPanel = false;
154 public void deleteColourByJmol()
156 this._has_colourByJmol = false;
161 public void deleteColourwithAlignPanel()
163 this._has_colourwithAlignPanel = false;
168 public void deleteHeight()
170 this._has_height = false;
175 public void deleteVisible()
177 this._has_visible = false;
182 public void deleteWidth()
184 this._has_width = false;
189 public void deleteXpos()
191 this._has_xpos = false;
196 public void deleteYpos()
198 this._has_ypos = false;
202 * Returns the value of field 'alignwithAlignPanel'. The field
203 * 'alignwithAlignPanel' has the following description: Flag set if the
204 * alignment panel containing this JSeq should be included in those used to
205 * perform a structure superposition (since Jalview 2.7).
208 * @return the value of field 'AlignwithAlignPanel'.
210 public boolean getAlignwithAlignPanel()
212 return this._alignwithAlignPanel;
216 * Returns the value of field 'colourByJmol'. The field 'colourByJmol' has the
217 * following description: Flag set if the structure display is coloured by the
218 * Jmol state, rather than by one or more linked alignment views.
221 * @return the value of field 'ColourByJmol'.
223 public boolean getColourByJmol()
225 return this._colourByJmol;
229 * Returns the value of field 'colourwithAlignPanel'. The field
230 * 'colourwithAlignPanel' has the following description: Flag set if the
231 * alignment panel containing this JSeq should be included in those used to
232 * colour its associated sequences in this structureState(since Jalview 2.7).
235 * @return the value of field 'ColourwithAlignPanel'.
237 public boolean getColourwithAlignPanel()
239 return this._colourwithAlignPanel;
243 * Returns the value of field 'content'. The field 'content' has the following
244 * description: internal content storage
246 * @return the value of field 'Content'.
248 public java.lang.String getContent()
250 return this._content;
254 * Returns the value of field 'height'.
256 * @return the value of field 'Height'.
258 public int getHeight()
264 * Returns the value of field 'viewId'. The field 'viewId' has the following
265 * description: additional identifier which properly disambiguates the
266 * structure view from any other view with the same attributes. This is not an
267 * ID, because it is possible to have many references to the same physical
268 * structure view from different sequences in an alignment. A structureState
269 * element citing the same viewId will appear for each instance.
272 * @return the value of field 'ViewId'.
274 public java.lang.String getViewId()
280 * Returns the value of field 'visible'.
282 * @return the value of field 'Visible'.
284 public boolean getVisible()
286 return this._visible;
290 * Returns the value of field 'width'.
292 * @return the value of field 'Width'.
294 public int getWidth()
300 * Returns the value of field 'xpos'.
302 * @return the value of field 'Xpos'.
310 * Returns the value of field 'ypos'.
312 * @return the value of field 'Ypos'.
320 * Method hasAlignwithAlignPanel.
322 * @return true if at least one AlignwithAlignPanel has been added
324 public boolean hasAlignwithAlignPanel()
326 return this._has_alignwithAlignPanel;
330 * Method hasColourByJmol.
332 * @return true if at least one ColourByJmol has been added
334 public boolean hasColourByJmol()
336 return this._has_colourByJmol;
340 * Method hasColourwithAlignPanel.
342 * @return true if at least one ColourwithAlignPanel has been added
344 public boolean hasColourwithAlignPanel()
346 return this._has_colourwithAlignPanel;
352 * @return true if at least one Height has been added
354 public boolean hasHeight()
356 return this._has_height;
362 * @return true if at least one Visible has been added
364 public boolean hasVisible()
366 return this._has_visible;
372 * @return true if at least one Width has been added
374 public boolean hasWidth()
376 return this._has_width;
382 * @return true if at least one Xpos has been added
384 public boolean hasXpos()
386 return this._has_xpos;
392 * @return true if at least one Ypos has been added
394 public boolean hasYpos()
396 return this._has_ypos;
400 * Returns the value of field 'alignwithAlignPanel'. The field
401 * 'alignwithAlignPanel' has the following description: Flag set if the
402 * alignment panel containing this JSeq should be included in those used to
403 * perform a structure superposition (since Jalview 2.7).
406 * @return the value of field 'AlignwithAlignPanel'.
408 public boolean isAlignwithAlignPanel()
410 return this._alignwithAlignPanel;
414 * Returns the value of field 'colourByJmol'. The field 'colourByJmol' has the
415 * following description: Flag set if the structure display is coloured by the
416 * Jmol state, rather than by one or more linked alignment views.
419 * @return the value of field 'ColourByJmol'.
421 public boolean isColourByJmol()
423 return this._colourByJmol;
427 * Returns the value of field 'colourwithAlignPanel'. The field
428 * 'colourwithAlignPanel' has the following description: Flag set if the
429 * alignment panel containing this JSeq should be included in those used to
430 * colour its associated sequences in this structureState(since Jalview 2.7).
433 * @return the value of field 'ColourwithAlignPanel'.
435 public boolean isColourwithAlignPanel()
437 return this._colourwithAlignPanel;
443 * @return true if this object is valid according to the schema
445 public boolean isValid()
450 } catch (org.exolab.castor.xml.ValidationException vex)
458 * Returns the value of field 'visible'.
460 * @return the value of field 'Visible'.
462 public boolean isVisible()
464 return this._visible;
471 * @throws org.exolab.castor.xml.MarshalException
472 * if object is null or if any SAXException is thrown during
474 * @throws org.exolab.castor.xml.ValidationException
475 * if this object is an invalid instance according to the schema
477 public void marshal(final java.io.Writer out)
478 throws org.exolab.castor.xml.MarshalException,
479 org.exolab.castor.xml.ValidationException
481 Marshaller.marshal(this, out);
488 * @throws java.io.IOException
489 * if an IOException occurs during marshaling
490 * @throws org.exolab.castor.xml.ValidationException
491 * if this object is an invalid instance according to the schema
492 * @throws org.exolab.castor.xml.MarshalException
493 * if object is null or if any SAXException is thrown during
496 public void marshal(final org.xml.sax.ContentHandler handler)
497 throws java.io.IOException,
498 org.exolab.castor.xml.MarshalException,
499 org.exolab.castor.xml.ValidationException
501 Marshaller.marshal(this, handler);
505 * Sets the value of field 'alignwithAlignPanel'. The field
506 * 'alignwithAlignPanel' has the following description: Flag set if the
507 * alignment panel containing this JSeq should be included in those used to
508 * perform a structure superposition (since Jalview 2.7).
511 * @param alignwithAlignPanel
512 * the value of field 'alignwithAlignPanel'.
514 public void setAlignwithAlignPanel(final boolean alignwithAlignPanel)
516 this._alignwithAlignPanel = alignwithAlignPanel;
517 this._has_alignwithAlignPanel = true;
521 * Sets the value of field 'colourByJmol'. The field 'colourByJmol' has the
522 * following description: Flag set if the structure display is coloured by the
523 * Jmol state, rather than by one or more linked alignment views.
526 * @param colourByJmol
527 * the value of field 'colourByJmol'.
529 public void setColourByJmol(final boolean colourByJmol)
531 this._colourByJmol = colourByJmol;
532 this._has_colourByJmol = true;
536 * Sets the value of field 'colourwithAlignPanel'. The field
537 * 'colourwithAlignPanel' has the following description: Flag set if the
538 * alignment panel containing this JSeq should be included in those used to
539 * colour its associated sequences in this structureState(since Jalview 2.7).
542 * @param colourwithAlignPanel
543 * the value of field 'colourwithAlignPanel'.
545 public void setColourwithAlignPanel(final boolean colourwithAlignPanel)
547 this._colourwithAlignPanel = colourwithAlignPanel;
548 this._has_colourwithAlignPanel = true;
552 * Sets the value of field 'content'. The field 'content' has the following
553 * description: internal content storage
556 * the value of field 'content'.
558 public void setContent(final java.lang.String content)
560 this._content = content;
564 * Sets the value of field 'height'.
567 * the value of field 'height'.
569 public void setHeight(final int height)
571 this._height = height;
572 this._has_height = true;
576 * Sets the value of field 'viewId'. The field 'viewId' has the following
577 * description: additional identifier which properly disambiguates the
578 * structure view from any other view with the same attributes. This is not an
579 * ID, because it is possible to have many references to the same physical
580 * structure view from different sequences in an alignment. A structureState
581 * element citing the same viewId will appear for each instance.
585 * the value of field 'viewId'.
587 public void setViewId(final java.lang.String viewId)
589 this._viewId = viewId;
593 * Sets the value of field 'visible'.
596 * the value of field 'visible'.
598 public void setVisible(final boolean visible)
600 this._visible = visible;
601 this._has_visible = true;
605 * Sets the value of field 'width'.
608 * the value of field 'width'.
610 public void setWidth(final int width)
613 this._has_width = true;
617 * Sets the value of field 'xpos'.
620 * the value of field 'xpos'.
622 public void setXpos(final int xpos)
625 this._has_xpos = true;
629 * Sets the value of field 'ypos'.
632 * the value of field 'ypos'.
634 public void setYpos(final int ypos)
637 this._has_ypos = true;
644 * @throws org.exolab.castor.xml.MarshalException
645 * if object is null or if any SAXException is thrown during
647 * @throws org.exolab.castor.xml.ValidationException
648 * if this object is an invalid instance according to the schema
649 * @return the unmarshaled jalview.schemabinding.version2.StructureState
651 public static jalview.schemabinding.version2.StructureState unmarshal(
652 final java.io.Reader reader)
653 throws org.exolab.castor.xml.MarshalException,
654 org.exolab.castor.xml.ValidationException
656 return (jalview.schemabinding.version2.StructureState) Unmarshaller
657 .unmarshal(jalview.schemabinding.version2.StructureState.class,
664 * @throws org.exolab.castor.xml.ValidationException
665 * if this object is an invalid instance according to the schema
667 public void validate() throws org.exolab.castor.xml.ValidationException
669 org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
670 validator.validate(this);