JAL-1503 update version in GPL header
[jalview.git] / src / jalview / schemabinding / version2 / OtherData.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 OtherData.
38  * 
39  * @version $Revision$ $Date$
40  */
41 public class OtherData implements java.io.Serializable
42 {
43
44   // --------------------------/
45   // - Class/Member Variables -/
46   // --------------------------/
47
48   /**
49    * Field _key.
50    */
51   private java.lang.String _key;
52
53   /**
54    * Field _value.
55    */
56   private java.lang.String _value;
57
58   // ----------------/
59   // - Constructors -/
60   // ----------------/
61
62   public OtherData()
63   {
64     super();
65   }
66
67   // -----------/
68   // - Methods -/
69   // -----------/
70
71   /**
72    * Returns the value of field 'key'.
73    * 
74    * @return the value of field 'Key'.
75    */
76   public java.lang.String getKey()
77   {
78     return this._key;
79   }
80
81   /**
82    * Returns the value of field 'value'.
83    * 
84    * @return the value of field 'Value'.
85    */
86   public java.lang.String getValue()
87   {
88     return this._value;
89   }
90
91   /**
92    * Method isValid.
93    * 
94    * @return true if this object is valid according to the schema
95    */
96   public boolean isValid()
97   {
98     try
99     {
100       validate();
101     } catch (org.exolab.castor.xml.ValidationException vex)
102     {
103       return false;
104     }
105     return true;
106   }
107
108   /**
109    * 
110    * 
111    * @param out
112    * @throws org.exolab.castor.xml.MarshalException
113    *           if object is null or if any SAXException is thrown during
114    *           marshaling
115    * @throws org.exolab.castor.xml.ValidationException
116    *           if this object is an invalid instance according to the schema
117    */
118   public void marshal(final java.io.Writer out)
119           throws org.exolab.castor.xml.MarshalException,
120           org.exolab.castor.xml.ValidationException
121   {
122     Marshaller.marshal(this, out);
123   }
124
125   /**
126    * 
127    * 
128    * @param handler
129    * @throws java.io.IOException
130    *           if an IOException occurs during marshaling
131    * @throws org.exolab.castor.xml.ValidationException
132    *           if this object is an invalid instance according to the schema
133    * @throws org.exolab.castor.xml.MarshalException
134    *           if object is null or if any SAXException is thrown during
135    *           marshaling
136    */
137   public void marshal(final org.xml.sax.ContentHandler handler)
138           throws java.io.IOException,
139           org.exolab.castor.xml.MarshalException,
140           org.exolab.castor.xml.ValidationException
141   {
142     Marshaller.marshal(this, handler);
143   }
144
145   /**
146    * Sets the value of field 'key'.
147    * 
148    * @param key
149    *          the value of field 'key'.
150    */
151   public void setKey(final java.lang.String key)
152   {
153     this._key = key;
154   }
155
156   /**
157    * Sets the value of field 'value'.
158    * 
159    * @param value
160    *          the value of field 'value'.
161    */
162   public void setValue(final java.lang.String value)
163   {
164     this._value = value;
165   }
166
167   /**
168    * Method unmarshal.
169    * 
170    * @param reader
171    * @throws org.exolab.castor.xml.MarshalException
172    *           if object is null or if any SAXException is thrown during
173    *           marshaling
174    * @throws org.exolab.castor.xml.ValidationException
175    *           if this object is an invalid instance according to the schema
176    * @return the unmarshaled jalview.schemabinding.version2.OtherData
177    */
178   public static jalview.schemabinding.version2.OtherData unmarshal(
179           final java.io.Reader reader)
180           throws org.exolab.castor.xml.MarshalException,
181           org.exolab.castor.xml.ValidationException
182   {
183     return (jalview.schemabinding.version2.OtherData) Unmarshaller
184             .unmarshal(jalview.schemabinding.version2.OtherData.class,
185                     reader);
186   }
187
188   /**
189    * 
190    * 
191    * @throws org.exolab.castor.xml.ValidationException
192    *           if this object is an invalid instance according to the schema
193    */
194   public void validate() throws org.exolab.castor.xml.ValidationException
195   {
196     org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
197     validator.validate(this);
198   }
199
200 }