1d5a34c45f3c8bcd3f42307489c3d0f3eb3d4f93
[jalview.git] / src / jalview / schemabinding / version2 / CalcIdParam.java
1 /*
2  * This class was automatically generated with 
3  * <a href="http://www.castor.org">Castor 1.1</a>, using an XML
4  * Schema.
5  * $Id$
6  */
7
8 package jalview.schemabinding.version2;
9
10 //---------------------------------/
11 //- Imported classes and packages -/
12 //---------------------------------/
13
14 import org.exolab.castor.xml.Marshaller;
15 import org.exolab.castor.xml.Unmarshaller;
16
17 /**
18  * Class CalcIdParam.
19  * 
20  * @version $Revision$ $Date$
21  */
22 public class CalcIdParam extends WebServiceParameterSet implements
23         java.io.Serializable
24 {
25
26   // --------------------------/
27   // - Class/Member Variables -/
28   // --------------------------/
29
30   /**
31    * handle for the calculation which uses this parameter set
32    */
33   private java.lang.String _calcId;
34
35   /**
36    * should the calculation be performed immediately after loading in order to
37    * refresh results
38    */
39   private boolean _needsUpdate = false;
40
41   /**
42    * keeps track of state for field: _needsUpdate
43    */
44   private boolean _has_needsUpdate;
45
46   /**
47    * should the calculation be automatically performed on edits
48    */
49   private boolean _autoUpdate;
50
51   /**
52    * keeps track of state for field: _autoUpdate
53    */
54   private boolean _has_autoUpdate;
55
56   // ----------------/
57   // - Constructors -/
58   // ----------------/
59
60   public CalcIdParam()
61   {
62     super();
63   }
64
65   // -----------/
66   // - Methods -/
67   // -----------/
68
69   /**
70      */
71   public void deleteAutoUpdate()
72   {
73     this._has_autoUpdate = false;
74   }
75
76   /**
77      */
78   public void deleteNeedsUpdate()
79   {
80     this._has_needsUpdate = false;
81   }
82
83   /**
84    * Returns the value of field 'autoUpdate'. The field 'autoUpdate' has the
85    * following description: should the calculation be automatically performed on
86    * edits
87    * 
88    * @return the value of field 'AutoUpdate'.
89    */
90   public boolean getAutoUpdate()
91   {
92     return this._autoUpdate;
93   }
94
95   /**
96    * Returns the value of field 'calcId'. The field 'calcId' has the following
97    * description: handle for the calculation which uses this parameter set
98    * 
99    * @return the value of field 'CalcId'.
100    */
101   public java.lang.String getCalcId()
102   {
103     return this._calcId;
104   }
105
106   /**
107    * Returns the value of field 'needsUpdate'. The field 'needsUpdate' has the
108    * following description: should the calculation be performed immediately
109    * after loading in order to refresh results
110    * 
111    * @return the value of field 'NeedsUpdate'.
112    */
113   public boolean getNeedsUpdate()
114   {
115     return this._needsUpdate;
116   }
117
118   /**
119    * Method hasAutoUpdate.
120    * 
121    * @return true if at least one AutoUpdate has been added
122    */
123   public boolean hasAutoUpdate()
124   {
125     return this._has_autoUpdate;
126   }
127
128   /**
129    * Method hasNeedsUpdate.
130    * 
131    * @return true if at least one NeedsUpdate has been added
132    */
133   public boolean hasNeedsUpdate()
134   {
135     return this._has_needsUpdate;
136   }
137
138   /**
139    * Returns the value of field 'autoUpdate'. The field 'autoUpdate' has the
140    * following description: should the calculation be automatically performed on
141    * edits
142    * 
143    * @return the value of field 'AutoUpdate'.
144    */
145   public boolean isAutoUpdate()
146   {
147     return this._autoUpdate;
148   }
149
150   /**
151    * Returns the value of field 'needsUpdate'. The field 'needsUpdate' has the
152    * following description: should the calculation be performed immediately
153    * after loading in order to refresh results
154    * 
155    * @return the value of field 'NeedsUpdate'.
156    */
157   public boolean isNeedsUpdate()
158   {
159     return this._needsUpdate;
160   }
161
162   /**
163    * Method isValid.
164    * 
165    * @return true if this object is valid according to the schema
166    */
167   public boolean isValid()
168   {
169     try
170     {
171       validate();
172     } catch (org.exolab.castor.xml.ValidationException vex)
173     {
174       return false;
175     }
176     return true;
177   }
178
179   /**
180    * 
181    * 
182    * @param out
183    * @throws org.exolab.castor.xml.MarshalException
184    *           if object is null or if any SAXException is thrown during
185    *           marshaling
186    * @throws org.exolab.castor.xml.ValidationException
187    *           if this object is an invalid instance according to the schema
188    */
189   public void marshal(final java.io.Writer out)
190           throws org.exolab.castor.xml.MarshalException,
191           org.exolab.castor.xml.ValidationException
192   {
193     Marshaller.marshal(this, out);
194   }
195
196   /**
197    * 
198    * 
199    * @param handler
200    * @throws java.io.IOException
201    *           if an IOException occurs during marshaling
202    * @throws org.exolab.castor.xml.ValidationException
203    *           if this object is an invalid instance according to the schema
204    * @throws org.exolab.castor.xml.MarshalException
205    *           if object is null or if any SAXException is thrown during
206    *           marshaling
207    */
208   public void marshal(final org.xml.sax.ContentHandler handler)
209           throws java.io.IOException,
210           org.exolab.castor.xml.MarshalException,
211           org.exolab.castor.xml.ValidationException
212   {
213     Marshaller.marshal(this, handler);
214   }
215
216   /**
217    * Sets the value of field 'autoUpdate'. The field 'autoUpdate' has the
218    * following description: should the calculation be automatically performed on
219    * edits
220    * 
221    * @param autoUpdate
222    *          the value of field 'autoUpdate'.
223    */
224   public void setAutoUpdate(final boolean autoUpdate)
225   {
226     this._autoUpdate = autoUpdate;
227     this._has_autoUpdate = true;
228   }
229
230   /**
231    * Sets the value of field 'calcId'. The field 'calcId' has the following
232    * description: handle for the calculation which uses this parameter set
233    * 
234    * @param calcId
235    *          the value of field 'calcId'.
236    */
237   public void setCalcId(final java.lang.String calcId)
238   {
239     this._calcId = calcId;
240   }
241
242   /**
243    * Sets the value of field 'needsUpdate'. The field 'needsUpdate' has the
244    * following description: should the calculation be performed immediately
245    * after loading in order to refresh results
246    * 
247    * @param needsUpdate
248    *          the value of field 'needsUpdate'.
249    */
250   public void setNeedsUpdate(final boolean needsUpdate)
251   {
252     this._needsUpdate = needsUpdate;
253     this._has_needsUpdate = true;
254   }
255
256   /**
257    * Method unmarshal.
258    * 
259    * @param reader
260    * @throws org.exolab.castor.xml.MarshalException
261    *           if object is null or if any SAXException is thrown during
262    *           marshaling
263    * @throws org.exolab.castor.xml.ValidationException
264    *           if this object is an invalid instance according to the schema
265    * @return the unmarshaled jalview.schemabinding.version2.CalcIdParam
266    */
267   public static jalview.schemabinding.version2.CalcIdParam unmarshal(
268           final java.io.Reader reader)
269           throws org.exolab.castor.xml.MarshalException,
270           org.exolab.castor.xml.ValidationException
271   {
272     return (jalview.schemabinding.version2.CalcIdParam) Unmarshaller
273             .unmarshal(jalview.schemabinding.version2.CalcIdParam.class,
274                     reader);
275   }
276
277   /**
278    * 
279    * 
280    * @throws org.exolab.castor.xml.ValidationException
281    *           if this object is an invalid instance according to the schema
282    */
283   public void validate() throws org.exolab.castor.xml.ValidationException
284   {
285     org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
286     validator.validate(this);
287   }
288
289 }