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
5 * This file is part of Jalview.
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.
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.
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 *******************************************************************************/
19 * This class was automatically generated with
20 * <a href="http://www.castor.org">Castor 1.1</a>, using an XML
25 package jalview.binding;
27 //---------------------------------/
28 //- Imported classes and packages -/
29 //---------------------------------/
31 import org.exolab.castor.xml.Marshaller;
32 import org.exolab.castor.xml.Unmarshaller;
37 * @version $Revision$ $Date$
39 public class Viewport implements java.io.Serializable {
42 //--------------------------/
43 //- Class/Member Variables -/
44 //--------------------------/
47 * Field _conservationSelected.
49 private boolean _conservationSelected;
52 * keeps track of state for field: _conservationSelected
54 private boolean _has_conservationSelected;
59 private boolean _pidSelected;
62 * keeps track of state for field: _pidSelected
64 private boolean _has_pidSelected;
69 private java.lang.String _bgColour;
72 * Field _consThreshold.
74 private int _consThreshold;
77 * keeps track of state for field: _consThreshold
79 private boolean _has_consThreshold;
82 * Field _pidThreshold.
84 private int _pidThreshold;
87 * keeps track of state for field: _pidThreshold
89 private boolean _has_pidThreshold;
94 private java.lang.String _title;
99 private boolean _showFullId;
102 * keeps track of state for field: _showFullId
104 private boolean _has_showFullId;
109 private boolean _showText;
112 * keeps track of state for field: _showText
114 private boolean _has_showText;
117 * Field _showColourText.
119 private boolean _showColourText;
122 * keeps track of state for field: _showColourText
124 private boolean _has_showColourText;
129 private boolean _showBoxes;
132 * keeps track of state for field: _showBoxes
134 private boolean _has_showBoxes;
137 * Field _wrapAlignment.
139 private boolean _wrapAlignment;
142 * keeps track of state for field: _wrapAlignment
144 private boolean _has_wrapAlignment;
149 private boolean _renderGaps;
152 * keeps track of state for field: _renderGaps
154 private boolean _has_renderGaps;
157 * Field _showSequenceFeatures.
159 private boolean _showSequenceFeatures;
162 * keeps track of state for field: _showSequenceFeatures
164 private boolean _has_showSequenceFeatures;
167 * Field _showAnnotation.
169 private boolean _showAnnotation;
172 * keeps track of state for field: _showAnnotation
174 private boolean _has_showAnnotation;
177 * Field _showConservation.
179 private boolean _showConservation;
182 * keeps track of state for field: _showConservation
184 private boolean _has_showConservation;
187 * Field _showQuality.
189 private boolean _showQuality;
192 * keeps track of state for field: _showQuality
194 private boolean _has_showQuality;
197 * Field _showIdentity.
199 private boolean _showIdentity;
202 * keeps track of state for field: _showIdentity
204 private boolean _has_showIdentity;
212 * keeps track of state for field: _xpos
214 private boolean _has_xpos;
222 * keeps track of state for field: _ypos
224 private boolean _has_ypos;
232 * keeps track of state for field: _width
234 private boolean _has_width;
242 * keeps track of state for field: _height
244 private boolean _has_height;
249 private int _startRes;
252 * keeps track of state for field: _startRes
254 private boolean _has_startRes;
259 private int _startSeq;
262 * keeps track of state for field: _startSeq
264 private boolean _has_startSeq;
269 private java.lang.String _fontName;
274 private int _fontSize;
277 * keeps track of state for field: _fontSize
279 private boolean _has_fontSize;
284 private int _fontStyle;
287 * keeps track of state for field: _fontStyle
289 private boolean _has_fontStyle;
307 public void deleteConsThreshold(
309 this._has_consThreshold= false;
314 public void deleteConservationSelected(
316 this._has_conservationSelected= false;
321 public void deleteFontSize(
323 this._has_fontSize= false;
328 public void deleteFontStyle(
330 this._has_fontStyle= false;
335 public void deleteHeight(
337 this._has_height= false;
342 public void deletePidSelected(
344 this._has_pidSelected= false;
349 public void deletePidThreshold(
351 this._has_pidThreshold= false;
356 public void deleteRenderGaps(
358 this._has_renderGaps= false;
363 public void deleteShowAnnotation(
365 this._has_showAnnotation= false;
370 public void deleteShowBoxes(
372 this._has_showBoxes= false;
377 public void deleteShowColourText(
379 this._has_showColourText= false;
384 public void deleteShowConservation(
386 this._has_showConservation= false;
391 public void deleteShowFullId(
393 this._has_showFullId= false;
398 public void deleteShowIdentity(
400 this._has_showIdentity= false;
405 public void deleteShowQuality(
407 this._has_showQuality= false;
412 public void deleteShowSequenceFeatures(
414 this._has_showSequenceFeatures= false;
419 public void deleteShowText(
421 this._has_showText= false;
426 public void deleteStartRes(
428 this._has_startRes= false;
433 public void deleteStartSeq(
435 this._has_startSeq= false;
440 public void deleteWidth(
442 this._has_width= false;
447 public void deleteWrapAlignment(
449 this._has_wrapAlignment= false;
454 public void deleteXpos(
456 this._has_xpos= false;
461 public void deleteYpos(
463 this._has_ypos= false;
467 * Returns the value of field 'bgColour'.
469 * @return the value of field 'BgColour'.
471 public java.lang.String getBgColour(
473 return this._bgColour;
477 * Returns the value of field 'consThreshold'.
479 * @return the value of field 'ConsThreshold'.
481 public int getConsThreshold(
483 return this._consThreshold;
487 * Returns the value of field 'conservationSelected'.
489 * @return the value of field 'ConservationSelected'.
491 public boolean getConservationSelected(
493 return this._conservationSelected;
497 * Returns the value of field 'fontName'.
499 * @return the value of field 'FontName'.
501 public java.lang.String getFontName(
503 return this._fontName;
507 * Returns the value of field 'fontSize'.
509 * @return the value of field 'FontSize'.
511 public int getFontSize(
513 return this._fontSize;
517 * Returns the value of field 'fontStyle'.
519 * @return the value of field 'FontStyle'.
521 public int getFontStyle(
523 return this._fontStyle;
527 * Returns the value of field 'height'.
529 * @return the value of field 'Height'.
531 public int getHeight(
537 * Returns the value of field 'pidSelected'.
539 * @return the value of field 'PidSelected'.
541 public boolean getPidSelected(
543 return this._pidSelected;
547 * Returns the value of field 'pidThreshold'.
549 * @return the value of field 'PidThreshold'.
551 public int getPidThreshold(
553 return this._pidThreshold;
557 * Returns the value of field 'renderGaps'.
559 * @return the value of field 'RenderGaps'.
561 public boolean getRenderGaps(
563 return this._renderGaps;
567 * Returns the value of field 'showAnnotation'.
569 * @return the value of field 'ShowAnnotation'.
571 public boolean getShowAnnotation(
573 return this._showAnnotation;
577 * Returns the value of field 'showBoxes'.
579 * @return the value of field 'ShowBoxes'.
581 public boolean getShowBoxes(
583 return this._showBoxes;
587 * Returns the value of field 'showColourText'.
589 * @return the value of field 'ShowColourText'.
591 public boolean getShowColourText(
593 return this._showColourText;
597 * Returns the value of field 'showConservation'.
599 * @return the value of field 'ShowConservation'.
601 public boolean getShowConservation(
603 return this._showConservation;
607 * Returns the value of field 'showFullId'.
609 * @return the value of field 'ShowFullId'.
611 public boolean getShowFullId(
613 return this._showFullId;
617 * Returns the value of field 'showIdentity'.
619 * @return the value of field 'ShowIdentity'.
621 public boolean getShowIdentity(
623 return this._showIdentity;
627 * Returns the value of field 'showQuality'.
629 * @return the value of field 'ShowQuality'.
631 public boolean getShowQuality(
633 return this._showQuality;
637 * Returns the value of field 'showSequenceFeatures'.
639 * @return the value of field 'ShowSequenceFeatures'.
641 public boolean getShowSequenceFeatures(
643 return this._showSequenceFeatures;
647 * Returns the value of field 'showText'.
649 * @return the value of field 'ShowText'.
651 public boolean getShowText(
653 return this._showText;
657 * Returns the value of field 'startRes'.
659 * @return the value of field 'StartRes'.
661 public int getStartRes(
663 return this._startRes;
667 * Returns the value of field 'startSeq'.
669 * @return the value of field 'StartSeq'.
671 public int getStartSeq(
673 return this._startSeq;
677 * Returns the value of field 'title'.
679 * @return the value of field 'Title'.
681 public java.lang.String getTitle(
687 * Returns the value of field 'width'.
689 * @return the value of field 'Width'.
697 * Returns the value of field 'wrapAlignment'.
699 * @return the value of field 'WrapAlignment'.
701 public boolean getWrapAlignment(
703 return this._wrapAlignment;
707 * Returns the value of field 'xpos'.
709 * @return the value of field 'Xpos'.
717 * Returns the value of field 'ypos'.
719 * @return the value of field 'Ypos'.
727 * Method hasConsThreshold.
729 * @return true if at least one ConsThreshold has been added
731 public boolean hasConsThreshold(
733 return this._has_consThreshold;
737 * Method hasConservationSelected.
739 * @return true if at least one ConservationSelected has been
742 public boolean hasConservationSelected(
744 return this._has_conservationSelected;
748 * Method hasFontSize.
750 * @return true if at least one FontSize has been added
752 public boolean hasFontSize(
754 return this._has_fontSize;
758 * Method hasFontStyle.
760 * @return true if at least one FontStyle has been added
762 public boolean hasFontStyle(
764 return this._has_fontStyle;
770 * @return true if at least one Height has been added
772 public boolean hasHeight(
774 return this._has_height;
778 * Method hasPidSelected.
780 * @return true if at least one PidSelected has been added
782 public boolean hasPidSelected(
784 return this._has_pidSelected;
788 * Method hasPidThreshold.
790 * @return true if at least one PidThreshold has been added
792 public boolean hasPidThreshold(
794 return this._has_pidThreshold;
798 * Method hasRenderGaps.
800 * @return true if at least one RenderGaps has been added
802 public boolean hasRenderGaps(
804 return this._has_renderGaps;
808 * Method hasShowAnnotation.
810 * @return true if at least one ShowAnnotation has been added
812 public boolean hasShowAnnotation(
814 return this._has_showAnnotation;
818 * Method hasShowBoxes.
820 * @return true if at least one ShowBoxes has been added
822 public boolean hasShowBoxes(
824 return this._has_showBoxes;
828 * Method hasShowColourText.
830 * @return true if at least one ShowColourText has been added
832 public boolean hasShowColourText(
834 return this._has_showColourText;
838 * Method hasShowConservation.
840 * @return true if at least one ShowConservation has been added
842 public boolean hasShowConservation(
844 return this._has_showConservation;
848 * Method hasShowFullId.
850 * @return true if at least one ShowFullId has been added
852 public boolean hasShowFullId(
854 return this._has_showFullId;
858 * Method hasShowIdentity.
860 * @return true if at least one ShowIdentity has been added
862 public boolean hasShowIdentity(
864 return this._has_showIdentity;
868 * Method hasShowQuality.
870 * @return true if at least one ShowQuality has been added
872 public boolean hasShowQuality(
874 return this._has_showQuality;
878 * Method hasShowSequenceFeatures.
880 * @return true if at least one ShowSequenceFeatures has been
883 public boolean hasShowSequenceFeatures(
885 return this._has_showSequenceFeatures;
889 * Method hasShowText.
891 * @return true if at least one ShowText has been added
893 public boolean hasShowText(
895 return this._has_showText;
899 * Method hasStartRes.
901 * @return true if at least one StartRes has been added
903 public boolean hasStartRes(
905 return this._has_startRes;
909 * Method hasStartSeq.
911 * @return true if at least one StartSeq has been added
913 public boolean hasStartSeq(
915 return this._has_startSeq;
921 * @return true if at least one Width has been added
923 public boolean hasWidth(
925 return this._has_width;
929 * Method hasWrapAlignment.
931 * @return true if at least one WrapAlignment has been added
933 public boolean hasWrapAlignment(
935 return this._has_wrapAlignment;
941 * @return true if at least one Xpos has been added
943 public boolean hasXpos(
945 return this._has_xpos;
951 * @return true if at least one Ypos has been added
953 public boolean hasYpos(
955 return this._has_ypos;
959 * Returns the value of field 'conservationSelected'.
961 * @return the value of field 'ConservationSelected'.
963 public boolean isConservationSelected(
965 return this._conservationSelected;
969 * Returns the value of field 'pidSelected'.
971 * @return the value of field 'PidSelected'.
973 public boolean isPidSelected(
975 return this._pidSelected;
979 * Returns the value of field 'renderGaps'.
981 * @return the value of field 'RenderGaps'.
983 public boolean isRenderGaps(
985 return this._renderGaps;
989 * Returns the value of field 'showAnnotation'.
991 * @return the value of field 'ShowAnnotation'.
993 public boolean isShowAnnotation(
995 return this._showAnnotation;
999 * Returns the value of field 'showBoxes'.
1001 * @return the value of field 'ShowBoxes'.
1003 public boolean isShowBoxes(
1005 return this._showBoxes;
1009 * Returns the value of field 'showColourText'.
1011 * @return the value of field 'ShowColourText'.
1013 public boolean isShowColourText(
1015 return this._showColourText;
1019 * Returns the value of field 'showConservation'.
1021 * @return the value of field 'ShowConservation'.
1023 public boolean isShowConservation(
1025 return this._showConservation;
1029 * Returns the value of field 'showFullId'.
1031 * @return the value of field 'ShowFullId'.
1033 public boolean isShowFullId(
1035 return this._showFullId;
1039 * Returns the value of field 'showIdentity'.
1041 * @return the value of field 'ShowIdentity'.
1043 public boolean isShowIdentity(
1045 return this._showIdentity;
1049 * Returns the value of field 'showQuality'.
1051 * @return the value of field 'ShowQuality'.
1053 public boolean isShowQuality(
1055 return this._showQuality;
1059 * Returns the value of field 'showSequenceFeatures'.
1061 * @return the value of field 'ShowSequenceFeatures'.
1063 public boolean isShowSequenceFeatures(
1065 return this._showSequenceFeatures;
1069 * Returns the value of field 'showText'.
1071 * @return the value of field 'ShowText'.
1073 public boolean isShowText(
1075 return this._showText;
1081 * @return true if this object is valid according to the schema
1083 public boolean isValid(
1087 } catch (org.exolab.castor.xml.ValidationException vex) {
1094 * Returns the value of field 'wrapAlignment'.
1096 * @return the value of field 'WrapAlignment'.
1098 public boolean isWrapAlignment(
1100 return this._wrapAlignment;
1107 * @throws org.exolab.castor.xml.MarshalException if object is
1108 * null or if any SAXException is thrown during marshaling
1109 * @throws org.exolab.castor.xml.ValidationException if this
1110 * object is an invalid instance according to the schema
1112 public void marshal(
1113 final java.io.Writer out)
1114 throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {
1115 Marshaller.marshal(this, out);
1122 * @throws java.io.IOException if an IOException occurs during
1124 * @throws org.exolab.castor.xml.ValidationException if this
1125 * object is an invalid instance according to the schema
1126 * @throws org.exolab.castor.xml.MarshalException if object is
1127 * null or if any SAXException is thrown during marshaling
1129 public void marshal(
1130 final org.xml.sax.ContentHandler handler)
1131 throws java.io.IOException, org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {
1132 Marshaller.marshal(this, handler);
1136 * Sets the value of field 'bgColour'.
1138 * @param bgColour the value of field 'bgColour'.
1140 public void setBgColour(
1141 final java.lang.String bgColour) {
1142 this._bgColour = bgColour;
1146 * Sets the value of field 'consThreshold'.
1148 * @param consThreshold the value of field 'consThreshold'.
1150 public void setConsThreshold(
1151 final int consThreshold) {
1152 this._consThreshold = consThreshold;
1153 this._has_consThreshold = true;
1157 * Sets the value of field 'conservationSelected'.
1159 * @param conservationSelected the value of field
1160 * 'conservationSelected'.
1162 public void setConservationSelected(
1163 final boolean conservationSelected) {
1164 this._conservationSelected = conservationSelected;
1165 this._has_conservationSelected = true;
1169 * Sets the value of field 'fontName'.
1171 * @param fontName the value of field 'fontName'.
1173 public void setFontName(
1174 final java.lang.String fontName) {
1175 this._fontName = fontName;
1179 * Sets the value of field 'fontSize'.
1181 * @param fontSize the value of field 'fontSize'.
1183 public void setFontSize(
1184 final int fontSize) {
1185 this._fontSize = fontSize;
1186 this._has_fontSize = true;
1190 * Sets the value of field 'fontStyle'.
1192 * @param fontStyle the value of field 'fontStyle'.
1194 public void setFontStyle(
1195 final int fontStyle) {
1196 this._fontStyle = fontStyle;
1197 this._has_fontStyle = true;
1201 * Sets the value of field 'height'.
1203 * @param height the value of field 'height'.
1205 public void setHeight(
1207 this._height = height;
1208 this._has_height = true;
1212 * Sets the value of field 'pidSelected'.
1214 * @param pidSelected the value of field 'pidSelected'.
1216 public void setPidSelected(
1217 final boolean pidSelected) {
1218 this._pidSelected = pidSelected;
1219 this._has_pidSelected = true;
1223 * Sets the value of field 'pidThreshold'.
1225 * @param pidThreshold the value of field 'pidThreshold'.
1227 public void setPidThreshold(
1228 final int pidThreshold) {
1229 this._pidThreshold = pidThreshold;
1230 this._has_pidThreshold = true;
1234 * Sets the value of field 'renderGaps'.
1236 * @param renderGaps the value of field 'renderGaps'.
1238 public void setRenderGaps(
1239 final boolean renderGaps) {
1240 this._renderGaps = renderGaps;
1241 this._has_renderGaps = true;
1245 * Sets the value of field 'showAnnotation'.
1247 * @param showAnnotation the value of field 'showAnnotation'.
1249 public void setShowAnnotation(
1250 final boolean showAnnotation) {
1251 this._showAnnotation = showAnnotation;
1252 this._has_showAnnotation = true;
1256 * Sets the value of field 'showBoxes'.
1258 * @param showBoxes the value of field 'showBoxes'.
1260 public void setShowBoxes(
1261 final boolean showBoxes) {
1262 this._showBoxes = showBoxes;
1263 this._has_showBoxes = true;
1267 * Sets the value of field 'showColourText'.
1269 * @param showColourText the value of field 'showColourText'.
1271 public void setShowColourText(
1272 final boolean showColourText) {
1273 this._showColourText = showColourText;
1274 this._has_showColourText = true;
1278 * Sets the value of field 'showConservation'.
1280 * @param showConservation the value of field 'showConservation'
1282 public void setShowConservation(
1283 final boolean showConservation) {
1284 this._showConservation = showConservation;
1285 this._has_showConservation = true;
1289 * Sets the value of field 'showFullId'.
1291 * @param showFullId the value of field 'showFullId'.
1293 public void setShowFullId(
1294 final boolean showFullId) {
1295 this._showFullId = showFullId;
1296 this._has_showFullId = true;
1300 * Sets the value of field 'showIdentity'.
1302 * @param showIdentity the value of field 'showIdentity'.
1304 public void setShowIdentity(
1305 final boolean showIdentity) {
1306 this._showIdentity = showIdentity;
1307 this._has_showIdentity = true;
1311 * Sets the value of field 'showQuality'.
1313 * @param showQuality the value of field 'showQuality'.
1315 public void setShowQuality(
1316 final boolean showQuality) {
1317 this._showQuality = showQuality;
1318 this._has_showQuality = true;
1322 * Sets the value of field 'showSequenceFeatures'.
1324 * @param showSequenceFeatures the value of field
1325 * 'showSequenceFeatures'.
1327 public void setShowSequenceFeatures(
1328 final boolean showSequenceFeatures) {
1329 this._showSequenceFeatures = showSequenceFeatures;
1330 this._has_showSequenceFeatures = true;
1334 * Sets the value of field 'showText'.
1336 * @param showText the value of field 'showText'.
1338 public void setShowText(
1339 final boolean showText) {
1340 this._showText = showText;
1341 this._has_showText = true;
1345 * Sets the value of field 'startRes'.
1347 * @param startRes the value of field 'startRes'.
1349 public void setStartRes(
1350 final int startRes) {
1351 this._startRes = startRes;
1352 this._has_startRes = true;
1356 * Sets the value of field 'startSeq'.
1358 * @param startSeq the value of field 'startSeq'.
1360 public void setStartSeq(
1361 final int startSeq) {
1362 this._startSeq = startSeq;
1363 this._has_startSeq = true;
1367 * Sets the value of field 'title'.
1369 * @param title the value of field 'title'.
1371 public void setTitle(
1372 final java.lang.String title) {
1373 this._title = title;
1377 * Sets the value of field 'width'.
1379 * @param width the value of field 'width'.
1381 public void setWidth(
1383 this._width = width;
1384 this._has_width = true;
1388 * Sets the value of field 'wrapAlignment'.
1390 * @param wrapAlignment the value of field 'wrapAlignment'.
1392 public void setWrapAlignment(
1393 final boolean wrapAlignment) {
1394 this._wrapAlignment = wrapAlignment;
1395 this._has_wrapAlignment = true;
1399 * Sets the value of field 'xpos'.
1401 * @param xpos the value of field 'xpos'.
1403 public void setXpos(
1406 this._has_xpos = true;
1410 * Sets the value of field 'ypos'.
1412 * @param ypos the value of field 'ypos'.
1414 public void setYpos(
1417 this._has_ypos = true;
1424 * @throws org.exolab.castor.xml.MarshalException if object is
1425 * null or if any SAXException is thrown during marshaling
1426 * @throws org.exolab.castor.xml.ValidationException if this
1427 * object is an invalid instance according to the schema
1428 * @return the unmarshaled jalview.binding.Viewport
1430 public static jalview.binding.Viewport unmarshal(
1431 final java.io.Reader reader)
1432 throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {
1433 return (jalview.binding.Viewport) Unmarshaller.unmarshal(jalview.binding.Viewport.class, reader);
1439 * @throws org.exolab.castor.xml.ValidationException if this
1440 * object is an invalid instance according to the schema
1442 public void validate(
1444 throws org.exolab.castor.xml.ValidationException {
1445 org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
1446 validator.validate(this);