2 * This class was automatically generated with
3 * <a href="http://www.castor.org">Castor 1.1</a>, using an XML
8 package jalview.binding;
10 //---------------------------------/
11 //- Imported classes and packages -/
12 //---------------------------------/
14 import org.exolab.castor.xml.Marshaller;
15 import org.exolab.castor.xml.Unmarshaller;
20 * @version $Revision$ $Date$
22 public class Setting implements java.io.Serializable
25 // --------------------------/
26 // - Class/Member Variables -/
27 // --------------------------/
32 private java.lang.String _type;
40 * keeps track of state for field: _colour
42 private boolean _has_colour;
47 private boolean _display;
50 * keeps track of state for field: _display
52 private boolean _has_display;
69 public void deleteColour()
71 this._has_colour = false;
76 public void deleteDisplay()
78 this._has_display = false;
82 * Returns the value of field 'colour'.
84 * @return the value of field 'Colour'.
86 public int getColour()
92 * Returns the value of field 'display'.
94 * @return the value of field 'Display'.
96 public boolean getDisplay()
102 * Returns the value of field 'type'.
104 * @return the value of field 'Type'.
106 public java.lang.String getType()
114 * @return true if at least one Colour has been added
116 public boolean hasColour()
118 return this._has_colour;
124 * @return true if at least one Display has been added
126 public boolean hasDisplay()
128 return this._has_display;
132 * Returns the value of field 'display'.
134 * @return the value of field 'Display'.
136 public boolean isDisplay()
138 return this._display;
144 * @return true if this object is valid according to the schema
146 public boolean isValid()
151 } catch (org.exolab.castor.xml.ValidationException vex)
162 * @throws org.exolab.castor.xml.MarshalException
163 * if object is null or if any SAXException is thrown during
165 * @throws org.exolab.castor.xml.ValidationException
166 * if this object is an invalid instance according to the schema
168 public void marshal(final java.io.Writer out)
169 throws org.exolab.castor.xml.MarshalException,
170 org.exolab.castor.xml.ValidationException
172 Marshaller.marshal(this, out);
179 * @throws java.io.IOException
180 * if an IOException occurs during marshaling
181 * @throws org.exolab.castor.xml.ValidationException
182 * if this object is an invalid instance according to the schema
183 * @throws org.exolab.castor.xml.MarshalException
184 * if object is null or if any SAXException is thrown during
187 public void marshal(final org.xml.sax.ContentHandler handler)
188 throws java.io.IOException,
189 org.exolab.castor.xml.MarshalException,
190 org.exolab.castor.xml.ValidationException
192 Marshaller.marshal(this, handler);
196 * Sets the value of field 'colour'.
199 * the value of field 'colour'.
201 public void setColour(final int colour)
203 this._colour = colour;
204 this._has_colour = true;
208 * Sets the value of field 'display'.
211 * the value of field 'display'.
213 public void setDisplay(final boolean display)
215 this._display = display;
216 this._has_display = true;
220 * Sets the value of field 'type'.
223 * the value of field 'type'.
225 public void setType(final java.lang.String type)
234 * @throws org.exolab.castor.xml.MarshalException
235 * if object is null or if any SAXException is thrown during
237 * @throws org.exolab.castor.xml.ValidationException
238 * if this object is an invalid instance according to the schema
239 * @return the unmarshaled jalview.binding.Setting
241 public static jalview.binding.Setting unmarshal(
242 final java.io.Reader reader)
243 throws org.exolab.castor.xml.MarshalException,
244 org.exolab.castor.xml.ValidationException
246 return (jalview.binding.Setting) Unmarshaller.unmarshal(
247 jalview.binding.Setting.class, reader);
253 * @throws org.exolab.castor.xml.ValidationException
254 * if this object is an invalid instance according to the schema
256 public void validate() throws org.exolab.castor.xml.ValidationException
258 org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
259 validator.validate(this);