2 * This class was automatically generated with
\r
3 * <a href="http://www.castor.org">Castor 0.9.6</a>, using an XML
\r
7 package jalview.binding;
\r
9 import org.exolab.castor.xml.MarshalException;
\r
10 import org.exolab.castor.xml.Marshaller;
\r
11 import org.exolab.castor.xml.Unmarshaller;
\r
12 import org.exolab.castor.xml.ValidationException;
\r
14 import org.xml.sax.ContentHandler;
\r
16 //---------------------------------/
\r
17 //- Imported classes and packages -/
\r
18 //---------------------------------/
\r
19 import java.io.IOException;
\r
20 import java.io.Reader;
\r
21 import java.io.Serializable;
\r
22 import java.io.Writer;
\r
26 * Class AnnotationElement.
\r
28 * @version $Revision$ $Date$
\r
30 public class AnnotationElement implements java.io.Serializable
\r
32 //--------------------------/
\r
33 //- Class/Member Variables -/
\r
34 //--------------------------/
\r
39 private int _position;
\r
42 * keeps track of state for field: _position
\r
44 private boolean _has_position;
\r
47 * Field _displayCharacter
\r
49 private java.lang.String _displayCharacter;
\r
52 * Field _description
\r
54 private java.lang.String _description;
\r
57 * Field _secondaryStructure
\r
59 private java.lang.String _secondaryStructure;
\r
64 private float _value;
\r
67 * keeps track of state for field: _value
\r
69 private boolean _has_value;
\r
74 public AnnotationElement()
\r
79 //-- jalview.binding.AnnotationElement()
\r
85 public void deletePosition()
\r
87 this._has_position = false;
\r
90 //-- void deletePosition()
\r
93 * Method deleteValue
\r
96 public void deleteValue()
\r
98 this._has_value = false;
\r
101 //-- void deleteValue()
\r
104 * Returns the value of field 'description'.
\r
107 * @return the value of field 'description'.
\r
109 public java.lang.String getDescription()
\r
111 return this._description;
\r
114 //-- java.lang.String getDescription()
\r
117 * Returns the value of field 'displayCharacter'.
\r
120 * @return the value of field 'displayCharacter'.
\r
122 public java.lang.String getDisplayCharacter()
\r
124 return this._displayCharacter;
\r
127 //-- java.lang.String getDisplayCharacter()
\r
130 * Returns the value of field 'position'.
\r
133 * @return the value of field 'position'.
\r
135 public int getPosition()
\r
137 return this._position;
\r
140 //-- int getPosition()
\r
143 * Returns the value of field 'secondaryStructure'.
\r
146 * @return the value of field 'secondaryStructure'.
\r
148 public java.lang.String getSecondaryStructure()
\r
150 return this._secondaryStructure;
\r
153 //-- java.lang.String getSecondaryStructure()
\r
156 * Returns the value of field 'value'.
\r
159 * @return the value of field 'value'.
\r
161 public float getValue()
\r
163 return this._value;
\r
166 //-- float getValue()
\r
169 * Method hasPosition
\r
175 public boolean hasPosition()
\r
177 return this._has_position;
\r
180 //-- boolean hasPosition()
\r
189 public boolean hasValue()
\r
191 return this._has_value;
\r
194 //-- boolean hasValue()
\r
203 public boolean isValid()
\r
209 catch (org.exolab.castor.xml.ValidationException vex)
\r
217 //-- boolean isValid()
\r
226 public void marshal(java.io.Writer out)
\r
227 throws org.exolab.castor.xml.MarshalException,
\r
228 org.exolab.castor.xml.ValidationException
\r
230 Marshaller.marshal(this, out);
\r
233 //-- void marshal(java.io.Writer)
\r
242 public void marshal(org.xml.sax.ContentHandler handler)
\r
243 throws java.io.IOException, org.exolab.castor.xml.MarshalException,
\r
244 org.exolab.castor.xml.ValidationException
\r
246 Marshaller.marshal(this, handler);
\r
249 //-- void marshal(org.xml.sax.ContentHandler)
\r
252 * Sets the value of field 'description'.
\r
254 * @param description the value of field 'description'.
\r
256 public void setDescription(java.lang.String description)
\r
258 this._description = description;
\r
261 //-- void setDescription(java.lang.String)
\r
264 * Sets the value of field 'displayCharacter'.
\r
266 * @param displayCharacter the value of field 'displayCharacter'
\r
268 public void setDisplayCharacter(java.lang.String displayCharacter)
\r
270 this._displayCharacter = displayCharacter;
\r
273 //-- void setDisplayCharacter(java.lang.String)
\r
276 * Sets the value of field 'position'.
\r
278 * @param position the value of field 'position'.
\r
280 public void setPosition(int position)
\r
282 this._position = position;
\r
283 this._has_position = true;
\r
286 //-- void setPosition(int)
\r
289 * Sets the value of field 'secondaryStructure'.
\r
291 * @param secondaryStructure the value of field
\r
292 * 'secondaryStructure'.
\r
294 public void setSecondaryStructure(java.lang.String secondaryStructure)
\r
296 this._secondaryStructure = secondaryStructure;
\r
299 //-- void setSecondaryStructure(java.lang.String)
\r
302 * Sets the value of field 'value'.
\r
304 * @param value the value of field 'value'.
\r
306 public void setValue(float value)
\r
308 this._value = value;
\r
309 this._has_value = true;
\r
312 //-- void setValue(float)
\r
322 public static java.lang.Object unmarshal(java.io.Reader reader)
\r
323 throws org.exolab.castor.xml.MarshalException,
\r
324 org.exolab.castor.xml.ValidationException
\r
326 return (jalview.binding.AnnotationElement) Unmarshaller.unmarshal(jalview.binding.AnnotationElement.class,
\r
330 //-- java.lang.Object unmarshal(java.io.Reader)
\r
336 public void validate() throws org.exolab.castor.xml.ValidationException
\r
338 org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
\r
339 validator.validate(this);
\r
342 //-- void validate()
\r