Formatting
[jalview.git] / src / jalview / schemabinding / version2 / Setting.java
1 /*\r
2  * This class was automatically generated with\r
3  * <a href="http://www.castor.org">Castor 0.9.6</a>, using an XML\r
4  * Schema.\r
5  * $Id$\r
6  */\r
7 \r
8 package jalview.schemabinding.version2;\r
9 \r
10 //---------------------------------/\r
11 //- Imported classes and packages -/\r
12 //---------------------------------/\r
13 \r
14 import org.exolab.castor.xml.*;\r
15 \r
16 /**\r
17  * Class Setting.\r
18  *\r
19  * @version $Revision$ $Date$\r
20  */\r
21 public class Setting\r
22     implements java.io.Serializable\r
23 {\r
24 \r
25   //--------------------------/\r
26   //- Class/Member Variables -/\r
27   //--------------------------/\r
28 \r
29   /**\r
30    * Field _type\r
31    */\r
32   private java.lang.String _type;\r
33 \r
34   /**\r
35    * Field _colour\r
36    */\r
37   private int _colour;\r
38 \r
39   /**\r
40    * keeps track of state for field: _colour\r
41    */\r
42   private boolean _has_colour;\r
43 \r
44   /**\r
45    * Field _display\r
46    */\r
47   private boolean _display;\r
48 \r
49   /**\r
50    * keeps track of state for field: _display\r
51    */\r
52   private boolean _has_display;\r
53 \r
54   //----------------/\r
55   //- Constructors -/\r
56   //----------------/\r
57 \r
58   public Setting()\r
59   {\r
60     super();\r
61   } //-- jalview.schemabinding.version2.Setting()\r
62 \r
63   //-----------/\r
64   //- Methods -/\r
65   //-----------/\r
66 \r
67   /**\r
68    * Method deleteColour\r
69    *\r
70    */\r
71   public void deleteColour()\r
72   {\r
73     this._has_colour = false;\r
74   } //-- void deleteColour()\r
75 \r
76   /**\r
77    * Method deleteDisplay\r
78    *\r
79    */\r
80   public void deleteDisplay()\r
81   {\r
82     this._has_display = false;\r
83   } //-- void deleteDisplay()\r
84 \r
85   /**\r
86    * Returns the value of field 'colour'.\r
87    *\r
88    * @return int\r
89    * @return the value of field 'colour'.\r
90    */\r
91   public int getColour()\r
92   {\r
93     return this._colour;\r
94   } //-- int getColour()\r
95 \r
96   /**\r
97    * Returns the value of field 'display'.\r
98    *\r
99    * @return boolean\r
100    * @return the value of field 'display'.\r
101    */\r
102   public boolean getDisplay()\r
103   {\r
104     return this._display;\r
105   } //-- boolean getDisplay()\r
106 \r
107   /**\r
108    * Returns the value of field 'type'.\r
109    *\r
110    * @return String\r
111    * @return the value of field 'type'.\r
112    */\r
113   public java.lang.String getType()\r
114   {\r
115     return this._type;\r
116   } //-- java.lang.String getType()\r
117 \r
118   /**\r
119    * Method hasColour\r
120    *\r
121    *\r
122    *\r
123    * @return boolean\r
124    */\r
125   public boolean hasColour()\r
126   {\r
127     return this._has_colour;\r
128   } //-- boolean hasColour()\r
129 \r
130   /**\r
131    * Method hasDisplay\r
132    *\r
133    *\r
134    *\r
135    * @return boolean\r
136    */\r
137   public boolean hasDisplay()\r
138   {\r
139     return this._has_display;\r
140   } //-- boolean hasDisplay()\r
141 \r
142   /**\r
143    * Method isValid\r
144    *\r
145    *\r
146    *\r
147    * @return boolean\r
148    */\r
149   public boolean isValid()\r
150   {\r
151     try\r
152     {\r
153       validate();\r
154     }\r
155     catch (org.exolab.castor.xml.ValidationException vex)\r
156     {\r
157       return false;\r
158     }\r
159     return true;\r
160   } //-- boolean isValid()\r
161 \r
162   /**\r
163    * Method marshal\r
164    *\r
165    *\r
166    *\r
167    * @param out\r
168    */\r
169   public void marshal(java.io.Writer out)\r
170       throws org.exolab.castor.xml.MarshalException,\r
171       org.exolab.castor.xml.ValidationException\r
172   {\r
173 \r
174     Marshaller.marshal(this, out);\r
175   } //-- void marshal(java.io.Writer)\r
176 \r
177   /**\r
178    * Method marshal\r
179    *\r
180    *\r
181    *\r
182    * @param handler\r
183    */\r
184   public void marshal(org.xml.sax.ContentHandler handler)\r
185       throws java.io.IOException, org.exolab.castor.xml.MarshalException,\r
186       org.exolab.castor.xml.ValidationException\r
187   {\r
188 \r
189     Marshaller.marshal(this, handler);\r
190   } //-- void marshal(org.xml.sax.ContentHandler)\r
191 \r
192   /**\r
193    * Sets the value of field 'colour'.\r
194    *\r
195    * @param colour the value of field 'colour'.\r
196    */\r
197   public void setColour(int colour)\r
198   {\r
199     this._colour = colour;\r
200     this._has_colour = true;\r
201   } //-- void setColour(int)\r
202 \r
203   /**\r
204    * Sets the value of field 'display'.\r
205    *\r
206    * @param display the value of field 'display'.\r
207    */\r
208   public void setDisplay(boolean display)\r
209   {\r
210     this._display = display;\r
211     this._has_display = true;\r
212   } //-- void setDisplay(boolean)\r
213 \r
214   /**\r
215    * Sets the value of field 'type'.\r
216    *\r
217    * @param type the value of field 'type'.\r
218    */\r
219   public void setType(java.lang.String type)\r
220   {\r
221     this._type = type;\r
222   } //-- void setType(java.lang.String)\r
223 \r
224   /**\r
225    * Method unmarshal\r
226    *\r
227    *\r
228    *\r
229    * @param reader\r
230    * @return Object\r
231    */\r
232   public static java.lang.Object unmarshal(java.io.Reader reader)\r
233       throws org.exolab.castor.xml.MarshalException,\r
234       org.exolab.castor.xml.ValidationException\r
235   {\r
236     return (jalview.schemabinding.version2.Setting) Unmarshaller.unmarshal(\r
237         jalview.schemabinding.version2.Setting.class, reader);\r
238   } //-- java.lang.Object unmarshal(java.io.Reader)\r
239 \r
240   /**\r
241    * Method validate\r
242    *\r
243    */\r
244   public void validate()\r
245       throws org.exolab.castor.xml.ValidationException\r
246   {\r
247     org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.\r
248         Validator();\r
249     validator.validate(this);\r
250   } //-- void validate()\r
251 \r
252 }\r