modified castor-1.1 library and refactored uk.ac.vamsas
[jalview.git] / src / jalview / schemabinding / version2 / StructureState.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 StructureState.
19  * 
20  * @version $Revision$ $Date$
21  */
22 public class StructureState implements java.io.Serializable {
23
24
25       //--------------------------/
26      //- Class/Member Variables -/
27     //--------------------------/
28
29     /**
30      * internal content storage
31      */
32     private java.lang.String _content = "";
33
34     /**
35      * Field _visible.
36      */
37     private boolean _visible;
38
39     /**
40      * keeps track of state for field: _visible
41      */
42     private boolean _has_visible;
43
44     /**
45      * Field _xpos.
46      */
47     private int _xpos;
48
49     /**
50      * keeps track of state for field: _xpos
51      */
52     private boolean _has_xpos;
53
54     /**
55      * Field _ypos.
56      */
57     private int _ypos;
58
59     /**
60      * keeps track of state for field: _ypos
61      */
62     private boolean _has_ypos;
63
64     /**
65      * Field _width.
66      */
67     private int _width;
68
69     /**
70      * keeps track of state for field: _width
71      */
72     private boolean _has_width;
73
74     /**
75      * Field _height.
76      */
77     private int _height;
78
79     /**
80      * keeps track of state for field: _height
81      */
82     private boolean _has_height;
83
84
85       //----------------/
86      //- Constructors -/
87     //----------------/
88
89     public StructureState() {
90         super();
91         setContent("");
92     }
93
94
95       //-----------/
96      //- Methods -/
97     //-----------/
98
99     /**
100      */
101     public void deleteHeight(
102     ) {
103         this._has_height= false;
104     }
105
106     /**
107      */
108     public void deleteVisible(
109     ) {
110         this._has_visible= false;
111     }
112
113     /**
114      */
115     public void deleteWidth(
116     ) {
117         this._has_width= false;
118     }
119
120     /**
121      */
122     public void deleteXpos(
123     ) {
124         this._has_xpos= false;
125     }
126
127     /**
128      */
129     public void deleteYpos(
130     ) {
131         this._has_ypos= false;
132     }
133
134     /**
135      * Returns the value of field 'content'. The field 'content'
136      * has the following description: internal content storage
137      * 
138      * @return the value of field 'Content'.
139      */
140     public java.lang.String getContent(
141     ) {
142         return this._content;
143     }
144
145     /**
146      * Returns the value of field 'height'.
147      * 
148      * @return the value of field 'Height'.
149      */
150     public int getHeight(
151     ) {
152         return this._height;
153     }
154
155     /**
156      * Returns the value of field 'visible'.
157      * 
158      * @return the value of field 'Visible'.
159      */
160     public boolean getVisible(
161     ) {
162         return this._visible;
163     }
164
165     /**
166      * Returns the value of field 'width'.
167      * 
168      * @return the value of field 'Width'.
169      */
170     public int getWidth(
171     ) {
172         return this._width;
173     }
174
175     /**
176      * Returns the value of field 'xpos'.
177      * 
178      * @return the value of field 'Xpos'.
179      */
180     public int getXpos(
181     ) {
182         return this._xpos;
183     }
184
185     /**
186      * Returns the value of field 'ypos'.
187      * 
188      * @return the value of field 'Ypos'.
189      */
190     public int getYpos(
191     ) {
192         return this._ypos;
193     }
194
195     /**
196      * Method hasHeight.
197      * 
198      * @return true if at least one Height has been added
199      */
200     public boolean hasHeight(
201     ) {
202         return this._has_height;
203     }
204
205     /**
206      * Method hasVisible.
207      * 
208      * @return true if at least one Visible has been added
209      */
210     public boolean hasVisible(
211     ) {
212         return this._has_visible;
213     }
214
215     /**
216      * Method hasWidth.
217      * 
218      * @return true if at least one Width has been added
219      */
220     public boolean hasWidth(
221     ) {
222         return this._has_width;
223     }
224
225     /**
226      * Method hasXpos.
227      * 
228      * @return true if at least one Xpos has been added
229      */
230     public boolean hasXpos(
231     ) {
232         return this._has_xpos;
233     }
234
235     /**
236      * Method hasYpos.
237      * 
238      * @return true if at least one Ypos has been added
239      */
240     public boolean hasYpos(
241     ) {
242         return this._has_ypos;
243     }
244
245     /**
246      * Method isValid.
247      * 
248      * @return true if this object is valid according to the schema
249      */
250     public boolean isValid(
251     ) {
252         try {
253             validate();
254         } catch (org.exolab.castor.xml.ValidationException vex) {
255             return false;
256         }
257         return true;
258     }
259
260     /**
261      * Returns the value of field 'visible'.
262      * 
263      * @return the value of field 'Visible'.
264      */
265     public boolean isVisible(
266     ) {
267         return this._visible;
268     }
269
270     /**
271      * 
272      * 
273      * @param out
274      * @throws org.exolab.castor.xml.MarshalException if object is
275      * null or if any SAXException is thrown during marshaling
276      * @throws org.exolab.castor.xml.ValidationException if this
277      * object is an invalid instance according to the schema
278      */
279     public void marshal(
280             final java.io.Writer out)
281     throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {
282         Marshaller.marshal(this, out);
283     }
284
285     /**
286      * 
287      * 
288      * @param handler
289      * @throws java.io.IOException if an IOException occurs during
290      * marshaling
291      * @throws org.exolab.castor.xml.ValidationException if this
292      * object is an invalid instance according to the schema
293      * @throws org.exolab.castor.xml.MarshalException if object is
294      * null or if any SAXException is thrown during marshaling
295      */
296     public void marshal(
297             final org.xml.sax.ContentHandler handler)
298     throws java.io.IOException, org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {
299         Marshaller.marshal(this, handler);
300     }
301
302     /**
303      * Sets the value of field 'content'. The field 'content' has
304      * the following description: internal content storage
305      * 
306      * @param content the value of field 'content'.
307      */
308     public void setContent(
309             final java.lang.String content) {
310         this._content = content;
311     }
312
313     /**
314      * Sets the value of field 'height'.
315      * 
316      * @param height the value of field 'height'.
317      */
318     public void setHeight(
319             final int height) {
320         this._height = height;
321         this._has_height = true;
322     }
323
324     /**
325      * Sets the value of field 'visible'.
326      * 
327      * @param visible the value of field 'visible'.
328      */
329     public void setVisible(
330             final boolean visible) {
331         this._visible = visible;
332         this._has_visible = true;
333     }
334
335     /**
336      * Sets the value of field 'width'.
337      * 
338      * @param width the value of field 'width'.
339      */
340     public void setWidth(
341             final int width) {
342         this._width = width;
343         this._has_width = true;
344     }
345
346     /**
347      * Sets the value of field 'xpos'.
348      * 
349      * @param xpos the value of field 'xpos'.
350      */
351     public void setXpos(
352             final int xpos) {
353         this._xpos = xpos;
354         this._has_xpos = true;
355     }
356
357     /**
358      * Sets the value of field 'ypos'.
359      * 
360      * @param ypos the value of field 'ypos'.
361      */
362     public void setYpos(
363             final int ypos) {
364         this._ypos = ypos;
365         this._has_ypos = true;
366     }
367
368     /**
369      * Method unmarshal.
370      * 
371      * @param reader
372      * @throws org.exolab.castor.xml.MarshalException if object is
373      * null or if any SAXException is thrown during marshaling
374      * @throws org.exolab.castor.xml.ValidationException if this
375      * object is an invalid instance according to the schema
376      * @return the unmarshaled
377      * jalview.schemabinding.version2.StructureState
378      */
379     public static jalview.schemabinding.version2.StructureState unmarshal(
380             final java.io.Reader reader)
381     throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {
382         return (jalview.schemabinding.version2.StructureState) Unmarshaller.unmarshal(jalview.schemabinding.version2.StructureState.class, reader);
383     }
384
385     /**
386      * 
387      * 
388      * @throws org.exolab.castor.xml.ValidationException if this
389      * object is an invalid instance according to the schema
390      */
391     public void validate(
392     )
393     throws org.exolab.castor.xml.ValidationException {
394         org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
395         validator.validate(this);
396     }
397
398 }