JAL-1620 version bump and release notes
[jalview.git] / src / jalview / binding / JalviewModel.java
1 /*
2  * Jalview - A Sequence Alignment Editor and Viewer (Version 2.8.2b1)
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
10  * of the License, or (at your option) any later version.
11  *  
12  * Jalview is distributed in the hope that it will be useful, but 
13  * WITHOUT ANY WARRANTY; without even the implied warranty 
14  * of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
15  * PURPOSE.  See the GNU General Public License for more details.
16  * 
17  * You should have received a copy of the GNU General Public License
18  * along with Jalview.  If not, see <http://www.gnu.org/licenses/>.
19  * The Jalview Authors are detailed in the 'AUTHORS' file.
20  */
21 package jalview.binding;
22
23 //---------------------------------/
24 //- Imported classes and packages -/
25 //---------------------------------/
26
27 import org.exolab.castor.xml.Marshaller;
28 import org.exolab.castor.xml.Unmarshaller;
29
30 /**
31  * Class JalviewModel.
32  * 
33  * @version $Revision$ $Date$
34  */
35 public class JalviewModel implements java.io.Serializable
36 {
37
38   // --------------------------/
39   // - Class/Member Variables -/
40   // --------------------------/
41
42   /**
43    * Field _creationDate.
44    */
45   private java.util.Date _creationDate;
46
47   /**
48    * Field _version.
49    */
50   private java.lang.String _version;
51
52   /**
53    * Field _vamsasModel.
54    */
55   private jalview.binding.VamsasModel _vamsasModel;
56
57   /**
58    * Field _jalviewModelSequence.
59    */
60   private jalview.binding.JalviewModelSequence _jalviewModelSequence;
61
62   // ----------------/
63   // - Constructors -/
64   // ----------------/
65
66   public JalviewModel()
67   {
68     super();
69   }
70
71   // -----------/
72   // - Methods -/
73   // -----------/
74
75   /**
76    * Returns the value of field 'creationDate'.
77    * 
78    * @return the value of field 'CreationDate'.
79    */
80   public java.util.Date getCreationDate()
81   {
82     return this._creationDate;
83   }
84
85   /**
86    * Returns the value of field 'jalviewModelSequence'.
87    * 
88    * @return the value of field 'JalviewModelSequence'.
89    */
90   public jalview.binding.JalviewModelSequence getJalviewModelSequence()
91   {
92     return this._jalviewModelSequence;
93   }
94
95   /**
96    * Returns the value of field 'vamsasModel'.
97    * 
98    * @return the value of field 'VamsasModel'.
99    */
100   public jalview.binding.VamsasModel getVamsasModel()
101   {
102     return this._vamsasModel;
103   }
104
105   /**
106    * Returns the value of field 'version'.
107    * 
108    * @return the value of field 'Version'.
109    */
110   public java.lang.String getVersion()
111   {
112     return this._version;
113   }
114
115   /**
116    * Method isValid.
117    * 
118    * @return true if this object is valid according to the schema
119    */
120   public boolean isValid()
121   {
122     try
123     {
124       validate();
125     } catch (org.exolab.castor.xml.ValidationException vex)
126     {
127       return false;
128     }
129     return true;
130   }
131
132   /**
133    * 
134    * 
135    * @param out
136    * @throws org.exolab.castor.xml.MarshalException
137    *           if object is null or if any SAXException is thrown during
138    *           marshaling
139    * @throws org.exolab.castor.xml.ValidationException
140    *           if this object is an invalid instance according to the schema
141    */
142   public void marshal(final java.io.Writer out)
143           throws org.exolab.castor.xml.MarshalException,
144           org.exolab.castor.xml.ValidationException
145   {
146     Marshaller.marshal(this, out);
147   }
148
149   /**
150    * 
151    * 
152    * @param handler
153    * @throws java.io.IOException
154    *           if an IOException occurs during marshaling
155    * @throws org.exolab.castor.xml.ValidationException
156    *           if this object is an invalid instance according to the schema
157    * @throws org.exolab.castor.xml.MarshalException
158    *           if object is null or if any SAXException is thrown during
159    *           marshaling
160    */
161   public void marshal(final org.xml.sax.ContentHandler handler)
162           throws java.io.IOException,
163           org.exolab.castor.xml.MarshalException,
164           org.exolab.castor.xml.ValidationException
165   {
166     Marshaller.marshal(this, handler);
167   }
168
169   /**
170    * Sets the value of field 'creationDate'.
171    * 
172    * @param creationDate
173    *          the value of field 'creationDate'.
174    */
175   public void setCreationDate(final java.util.Date creationDate)
176   {
177     this._creationDate = creationDate;
178   }
179
180   /**
181    * Sets the value of field 'jalviewModelSequence'.
182    * 
183    * @param jalviewModelSequence
184    *          the value of field 'jalviewModelSequence'.
185    */
186   public void setJalviewModelSequence(
187           final jalview.binding.JalviewModelSequence jalviewModelSequence)
188   {
189     this._jalviewModelSequence = jalviewModelSequence;
190   }
191
192   /**
193    * Sets the value of field 'vamsasModel'.
194    * 
195    * @param vamsasModel
196    *          the value of field 'vamsasModel'.
197    */
198   public void setVamsasModel(final jalview.binding.VamsasModel vamsasModel)
199   {
200     this._vamsasModel = vamsasModel;
201   }
202
203   /**
204    * Sets the value of field 'version'.
205    * 
206    * @param version
207    *          the value of field 'version'.
208    */
209   public void setVersion(final java.lang.String version)
210   {
211     this._version = version;
212   }
213
214   /**
215    * Method unmarshal.
216    * 
217    * @param reader
218    * @throws org.exolab.castor.xml.MarshalException
219    *           if object is null or if any SAXException is thrown during
220    *           marshaling
221    * @throws org.exolab.castor.xml.ValidationException
222    *           if this object is an invalid instance according to the schema
223    * @return the unmarshaled jalview.binding.JalviewModel
224    */
225   public static jalview.binding.JalviewModel unmarshal(
226           final java.io.Reader reader)
227           throws org.exolab.castor.xml.MarshalException,
228           org.exolab.castor.xml.ValidationException
229   {
230     return (jalview.binding.JalviewModel) Unmarshaller.unmarshal(
231             jalview.binding.JalviewModel.class, reader);
232   }
233
234   /**
235    * 
236    * 
237    * @throws org.exolab.castor.xml.ValidationException
238    *           if this object is an invalid instance according to the schema
239    */
240   public void validate() throws org.exolab.castor.xml.ValidationException
241   {
242     org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
243     validator.validate(this);
244   }
245
246 }