JAL-1503 update version in GPL header
[jalview.git] / src / jalview / schemabinding / version2 / Alcodon.java
1 /*******************************************************************************
2  * Jalview - A Sequence Alignment Editor and Viewer (Version 2.8.1)
3  * Copyright (C) 2014 The Jalview Authors
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.  
17  * If not, see <http://www.gnu.org/licenses/>.
18  * The Jalview Authors are detailed in the 'AUTHORS' file.
19  ******************************************************************************/
20 /*
21  * This class was automatically generated with 
22  * <a href="http://www.castor.org">Castor 1.1</a>, using an XML
23  * Schema.
24  * $Id$
25  */
26
27 package jalview.schemabinding.version2;
28
29 //---------------------------------/
30 //- Imported classes and packages -/
31 //---------------------------------/
32
33 import org.exolab.castor.xml.Marshaller;
34 import org.exolab.castor.xml.Unmarshaller;
35
36 /**
37  * Class Alcodon.
38  * 
39  * @version $Revision$ $Date$
40  */
41 public class Alcodon implements java.io.Serializable
42 {
43
44   // --------------------------/
45   // - Class/Member Variables -/
46   // --------------------------/
47
48   /**
49    * Field _pos1.
50    */
51   private long _pos1;
52
53   /**
54    * keeps track of state for field: _pos1
55    */
56   private boolean _has_pos1;
57
58   /**
59    * Field _pos2.
60    */
61   private long _pos2;
62
63   /**
64    * keeps track of state for field: _pos2
65    */
66   private boolean _has_pos2;
67
68   /**
69    * Field _pos3.
70    */
71   private long _pos3;
72
73   /**
74    * keeps track of state for field: _pos3
75    */
76   private boolean _has_pos3;
77
78   // ----------------/
79   // - Constructors -/
80   // ----------------/
81
82   public Alcodon()
83   {
84     super();
85   }
86
87   // -----------/
88   // - Methods -/
89   // -----------/
90
91   /**
92      */
93   public void deletePos1()
94   {
95     this._has_pos1 = false;
96   }
97
98   /**
99      */
100   public void deletePos2()
101   {
102     this._has_pos2 = false;
103   }
104
105   /**
106      */
107   public void deletePos3()
108   {
109     this._has_pos3 = false;
110   }
111
112   /**
113    * Returns the value of field 'pos1'.
114    * 
115    * @return the value of field 'Pos1'.
116    */
117   public long getPos1()
118   {
119     return this._pos1;
120   }
121
122   /**
123    * Returns the value of field 'pos2'.
124    * 
125    * @return the value of field 'Pos2'.
126    */
127   public long getPos2()
128   {
129     return this._pos2;
130   }
131
132   /**
133    * Returns the value of field 'pos3'.
134    * 
135    * @return the value of field 'Pos3'.
136    */
137   public long getPos3()
138   {
139     return this._pos3;
140   }
141
142   /**
143    * Method hasPos1.
144    * 
145    * @return true if at least one Pos1 has been added
146    */
147   public boolean hasPos1()
148   {
149     return this._has_pos1;
150   }
151
152   /**
153    * Method hasPos2.
154    * 
155    * @return true if at least one Pos2 has been added
156    */
157   public boolean hasPos2()
158   {
159     return this._has_pos2;
160   }
161
162   /**
163    * Method hasPos3.
164    * 
165    * @return true if at least one Pos3 has been added
166    */
167   public boolean hasPos3()
168   {
169     return this._has_pos3;
170   }
171
172   /**
173    * Method isValid.
174    * 
175    * @return true if this object is valid according to the schema
176    */
177   public boolean isValid()
178   {
179     try
180     {
181       validate();
182     } catch (org.exolab.castor.xml.ValidationException vex)
183     {
184       return false;
185     }
186     return true;
187   }
188
189   /**
190    * 
191    * 
192    * @param out
193    * @throws org.exolab.castor.xml.MarshalException
194    *           if object is null or if any SAXException is thrown during
195    *           marshaling
196    * @throws org.exolab.castor.xml.ValidationException
197    *           if this object is an invalid instance according to the schema
198    */
199   public void marshal(final java.io.Writer out)
200           throws org.exolab.castor.xml.MarshalException,
201           org.exolab.castor.xml.ValidationException
202   {
203     Marshaller.marshal(this, out);
204   }
205
206   /**
207    * 
208    * 
209    * @param handler
210    * @throws java.io.IOException
211    *           if an IOException occurs during marshaling
212    * @throws org.exolab.castor.xml.ValidationException
213    *           if this object is an invalid instance according to the schema
214    * @throws org.exolab.castor.xml.MarshalException
215    *           if object is null or if any SAXException is thrown during
216    *           marshaling
217    */
218   public void marshal(final org.xml.sax.ContentHandler handler)
219           throws java.io.IOException,
220           org.exolab.castor.xml.MarshalException,
221           org.exolab.castor.xml.ValidationException
222   {
223     Marshaller.marshal(this, handler);
224   }
225
226   /**
227    * Sets the value of field 'pos1'.
228    * 
229    * @param pos1
230    *          the value of field 'pos1'.
231    */
232   public void setPos1(final long pos1)
233   {
234     this._pos1 = pos1;
235     this._has_pos1 = true;
236   }
237
238   /**
239    * Sets the value of field 'pos2'.
240    * 
241    * @param pos2
242    *          the value of field 'pos2'.
243    */
244   public void setPos2(final long pos2)
245   {
246     this._pos2 = pos2;
247     this._has_pos2 = true;
248   }
249
250   /**
251    * Sets the value of field 'pos3'.
252    * 
253    * @param pos3
254    *          the value of field 'pos3'.
255    */
256   public void setPos3(final long pos3)
257   {
258     this._pos3 = pos3;
259     this._has_pos3 = true;
260   }
261
262   /**
263    * Method unmarshal.
264    * 
265    * @param reader
266    * @throws org.exolab.castor.xml.MarshalException
267    *           if object is null or if any SAXException is thrown during
268    *           marshaling
269    * @throws org.exolab.castor.xml.ValidationException
270    *           if this object is an invalid instance according to the schema
271    * @return the unmarshaled jalview.schemabinding.version2.Alcodo
272    */
273   public static jalview.schemabinding.version2.Alcodon unmarshal(
274           final java.io.Reader reader)
275           throws org.exolab.castor.xml.MarshalException,
276           org.exolab.castor.xml.ValidationException
277   {
278     return (jalview.schemabinding.version2.Alcodon) Unmarshaller.unmarshal(
279             jalview.schemabinding.version2.Alcodon.class, reader);
280   }
281
282   /**
283    * 
284    * 
285    * @throws org.exolab.castor.xml.ValidationException
286    *           if this object is an invalid instance according to the schema
287    */
288   public void validate() throws org.exolab.castor.xml.ValidationException
289   {
290     org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
291     validator.validate(this);
292   }
293
294 }