2 * This class was automatically generated with
3 * <a href="http://www.castor.org">Castor 1.1</a>, using an XML
8 package jalview.schemabinding.version2;
10 //---------------------------------/
11 //- Imported classes and packages -/
12 //---------------------------------/
14 import org.exolab.castor.xml.Marshaller;
15 import org.exolab.castor.xml.Unmarshaller;
18 * Class AnnotationColours.
20 * @version $Revision$ $Date$
22 public class AnnotationColours implements java.io.Serializable {
25 //--------------------------/
26 //- Class/Member Variables -/
27 //--------------------------/
30 * Field _aboveThreshold.
32 private int _aboveThreshold;
35 * keeps track of state for field: _aboveThreshold
37 private boolean _has_aboveThreshold;
42 private java.lang.String _annotation;
47 private int _minColour;
50 * keeps track of state for field: _minColour
52 private boolean _has_minColour;
57 private int _maxColour;
60 * keeps track of state for field: _maxColour
62 private boolean _has_maxColour;
65 * Field _colourScheme.
67 private java.lang.String _colourScheme;
72 private float _threshold;
75 * keeps track of state for field: _threshold
77 private boolean _has_threshold;
84 public AnnotationColours() {
95 public void deleteAboveThreshold(
97 this._has_aboveThreshold= false;
102 public void deleteMaxColour(
104 this._has_maxColour= false;
109 public void deleteMinColour(
111 this._has_minColour= false;
116 public void deleteThreshold(
118 this._has_threshold= false;
122 * Returns the value of field 'aboveThreshold'.
124 * @return the value of field 'AboveThreshold'.
126 public int getAboveThreshold(
128 return this._aboveThreshold;
132 * Returns the value of field 'annotation'.
134 * @return the value of field 'Annotation'.
136 public java.lang.String getAnnotation(
138 return this._annotation;
142 * Returns the value of field 'colourScheme'.
144 * @return the value of field 'ColourScheme'.
146 public java.lang.String getColourScheme(
148 return this._colourScheme;
152 * Returns the value of field 'maxColour'.
154 * @return the value of field 'MaxColour'.
156 public int getMaxColour(
158 return this._maxColour;
162 * Returns the value of field 'minColour'.
164 * @return the value of field 'MinColour'.
166 public int getMinColour(
168 return this._minColour;
172 * Returns the value of field 'threshold'.
174 * @return the value of field 'Threshold'.
176 public float getThreshold(
178 return this._threshold;
182 * Method hasAboveThreshold.
184 * @return true if at least one AboveThreshold has been added
186 public boolean hasAboveThreshold(
188 return this._has_aboveThreshold;
192 * Method hasMaxColour.
194 * @return true if at least one MaxColour has been added
196 public boolean hasMaxColour(
198 return this._has_maxColour;
202 * Method hasMinColour.
204 * @return true if at least one MinColour has been added
206 public boolean hasMinColour(
208 return this._has_minColour;
212 * Method hasThreshold.
214 * @return true if at least one Threshold has been added
216 public boolean hasThreshold(
218 return this._has_threshold;
224 * @return true if this object is valid according to the schema
226 public boolean isValid(
230 } catch (org.exolab.castor.xml.ValidationException vex) {
240 * @throws org.exolab.castor.xml.MarshalException if object is
241 * null or if any SAXException is thrown during marshaling
242 * @throws org.exolab.castor.xml.ValidationException if this
243 * object is an invalid instance according to the schema
246 final java.io.Writer out)
247 throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {
248 Marshaller.marshal(this, out);
255 * @throws java.io.IOException if an IOException occurs during
257 * @throws org.exolab.castor.xml.ValidationException if this
258 * object is an invalid instance according to the schema
259 * @throws org.exolab.castor.xml.MarshalException if object is
260 * null or if any SAXException is thrown during marshaling
263 final org.xml.sax.ContentHandler handler)
264 throws java.io.IOException, org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {
265 Marshaller.marshal(this, handler);
269 * Sets the value of field 'aboveThreshold'.
271 * @param aboveThreshold the value of field 'aboveThreshold'.
273 public void setAboveThreshold(
274 final int aboveThreshold) {
275 this._aboveThreshold = aboveThreshold;
276 this._has_aboveThreshold = true;
280 * Sets the value of field 'annotation'.
282 * @param annotation the value of field 'annotation'.
284 public void setAnnotation(
285 final java.lang.String annotation) {
286 this._annotation = annotation;
290 * Sets the value of field 'colourScheme'.
292 * @param colourScheme the value of field 'colourScheme'.
294 public void setColourScheme(
295 final java.lang.String colourScheme) {
296 this._colourScheme = colourScheme;
300 * Sets the value of field 'maxColour'.
302 * @param maxColour the value of field 'maxColour'.
304 public void setMaxColour(
305 final int maxColour) {
306 this._maxColour = maxColour;
307 this._has_maxColour = true;
311 * Sets the value of field 'minColour'.
313 * @param minColour the value of field 'minColour'.
315 public void setMinColour(
316 final int minColour) {
317 this._minColour = minColour;
318 this._has_minColour = true;
322 * Sets the value of field 'threshold'.
324 * @param threshold the value of field 'threshold'.
326 public void setThreshold(
327 final float threshold) {
328 this._threshold = threshold;
329 this._has_threshold = true;
336 * @throws org.exolab.castor.xml.MarshalException if object is
337 * null or if any SAXException is thrown during marshaling
338 * @throws org.exolab.castor.xml.ValidationException if this
339 * object is an invalid instance according to the schema
340 * @return the unmarshaled
341 * jalview.schemabinding.version2.AnnotationColours
343 public static jalview.schemabinding.version2.AnnotationColours unmarshal(
344 final java.io.Reader reader)
345 throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException {
346 return (jalview.schemabinding.version2.AnnotationColours) Unmarshaller.unmarshal(jalview.schemabinding.version2.AnnotationColours.class, reader);
352 * @throws org.exolab.castor.xml.ValidationException if this
353 * object is an invalid instance according to the schema
355 public void validate(
357 throws org.exolab.castor.xml.ValidationException {
358 org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
359 validator.validate(this);