jalview XML schema update for 2.4.1 (or 2.5?) introducing IDs for views and treepanel...
[jalview.git] / src / jalview / schemabinding / version2 / MappingChoice.java
1 /*\r
2  * This class was automatically generated with \r
3  * <a href="http://www.castor.org">Castor 1.1</a>, using an XML\r
4  * Schema.\r
5  * $Id$\r
6  */\r
7 \r
8 package jalview.schemabinding.version2;\r
9 \r
10   //---------------------------------/\r
11  //- Imported classes and packages -/\r
12 //---------------------------------/\r
13 \r
14 import org.exolab.castor.xml.Marshaller;\r
15 import org.exolab.castor.xml.Unmarshaller;\r
16 \r
17 /**\r
18  * Class MappingChoice.\r
19  * \r
20  * @version $Revision$ $Date$\r
21  */\r
22 public class MappingChoice implements java.io.Serializable {\r
23 \r
24 \r
25       //--------------------------/\r
26      //- Class/Member Variables -/\r
27     //--------------------------/\r
28 \r
29     /**\r
30      * Field _sequence.\r
31      */\r
32     private jalview.schemabinding.version2.Sequence _sequence;\r
33 \r
34     /**\r
35      * Field _dseqFor.\r
36      */\r
37     private java.lang.String _dseqFor;\r
38 \r
39 \r
40       //----------------/\r
41      //- Constructors -/\r
42     //----------------/\r
43 \r
44     public MappingChoice() {\r
45         super();\r
46     }\r
47 \r
48 \r
49       //-----------/\r
50      //- Methods -/\r
51     //-----------/\r
52 \r
53     /**\r
54      * Returns the value of field 'dseqFor'.\r
55      * \r
56      * @return the value of field 'DseqFor'.\r
57      */\r
58     public java.lang.String getDseqFor(\r
59     ) {\r
60         return this._dseqFor;\r
61     }\r
62 \r
63     /**\r
64      * Returns the value of field 'sequence'.\r
65      * \r
66      * @return the value of field 'Sequence'.\r
67      */\r
68     public jalview.schemabinding.version2.Sequence getSequence(\r
69     ) {\r
70         return this._sequence;\r
71     }\r
72 \r
73     /**\r
74      * Method isValid.\r
75      * \r
76      * @return true if this object is valid according to the schema\r
77      */\r
78     public boolean isValid(\r
79     ) {\r
80         try {\r
81             validate();\r
82         } catch (org.exolab.castor.xml.ValidationException vex) {\r
83             return false;\r
84         }\r
85         return true;\r
86     }\r
87 \r
88     /**\r
89      * \r
90      * \r
91      * @param out\r
92      * @throws org.exolab.castor.xml.MarshalException if object is\r
93      * null or if any SAXException is thrown during marshaling\r
94      * @throws org.exolab.castor.xml.ValidationException if this\r
95      * object is an invalid instance according to the schema\r
96      */\r
97     public void marshal(\r
98             final java.io.Writer out)\r
99     throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {\r
100         Marshaller.marshal(this, out);\r
101     }\r
102 \r
103     /**\r
104      * \r
105      * \r
106      * @param handler\r
107      * @throws java.io.IOException if an IOException occurs during\r
108      * marshaling\r
109      * @throws org.exolab.castor.xml.ValidationException if this\r
110      * object is an invalid instance according to the schema\r
111      * @throws org.exolab.castor.xml.MarshalException if object is\r
112      * null or if any SAXException is thrown during marshaling\r
113      */\r
114     public void marshal(\r
115             final org.xml.sax.ContentHandler handler)\r
116     throws java.io.IOException, org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {\r
117         Marshaller.marshal(this, handler);\r
118     }\r
119 \r
120     /**\r
121      * Sets the value of field 'dseqFor'.\r
122      * \r
123      * @param dseqFor the value of field 'dseqFor'.\r
124      */\r
125     public void setDseqFor(\r
126             final java.lang.String dseqFor) {\r
127         this._dseqFor = dseqFor;\r
128     }\r
129 \r
130     /**\r
131      * Sets the value of field 'sequence'.\r
132      * \r
133      * @param sequence the value of field 'sequence'.\r
134      */\r
135     public void setSequence(\r
136             final jalview.schemabinding.version2.Sequence sequence) {\r
137         this._sequence = sequence;\r
138     }\r
139 \r
140     /**\r
141      * Method unmarshal.\r
142      * \r
143      * @param reader\r
144      * @throws org.exolab.castor.xml.MarshalException if object is\r
145      * null or if any SAXException is thrown during marshaling\r
146      * @throws org.exolab.castor.xml.ValidationException if this\r
147      * object is an invalid instance according to the schema\r
148      * @return the unmarshaled\r
149      * jalview.schemabinding.version2.MappingChoice\r
150      */\r
151     public static jalview.schemabinding.version2.MappingChoice unmarshal(\r
152             final java.io.Reader reader)\r
153     throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {\r
154         return (jalview.schemabinding.version2.MappingChoice) Unmarshaller.unmarshal(jalview.schemabinding.version2.MappingChoice.class, reader);\r
155     }\r
156 \r
157     /**\r
158      * \r
159      * \r
160      * @throws org.exolab.castor.xml.ValidationException if this\r
161      * object is an invalid instance according to the schema\r
162      */\r
163     public void validate(\r
164     )\r
165     throws org.exolab.castor.xml.ValidationException {\r
166         org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();\r
167         validator.validate(this);\r
168     }\r
169 \r
170 }\r