2 * This class was automatically generated with
\r
3 * <a href="http://www.castor.org">Castor 0.9.6</a>, using an XML
\r
8 package jalview.binding;
\r
10 //---------------------------------/
\r
11 //- Imported classes and packages -/
\r
12 //---------------------------------/
\r
14 import java.io.IOException;
\r
15 import java.io.Reader;
\r
16 import java.io.Serializable;
\r
17 import java.io.Writer;
\r
18 import org.exolab.castor.xml.MarshalException;
\r
19 import org.exolab.castor.xml.Marshaller;
\r
20 import org.exolab.castor.xml.Unmarshaller;
\r
21 import org.exolab.castor.xml.ValidationException;
\r
22 import org.xml.sax.ContentHandler;
\r
25 * Class AnnotationElement.
\r
27 * @version $Revision$ $Date$
\r
29 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
76 public AnnotationElement() {
\r
78 } //-- jalview.binding.AnnotationElement()
\r
86 * Method deletePosition
\r
89 public void deletePosition()
\r
91 this._has_position= false;
\r
92 } //-- void deletePosition()
\r
95 * Method deleteValue
\r
98 public void deleteValue()
\r
100 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
112 } //-- java.lang.String getDescription()
\r
115 * Returns the value of field 'displayCharacter'.
\r
118 * @return the value of field 'displayCharacter'.
\r
120 public java.lang.String getDisplayCharacter()
\r
122 return this._displayCharacter;
\r
123 } //-- java.lang.String getDisplayCharacter()
\r
126 * Returns the value of field 'position'.
\r
129 * @return the value of field 'position'.
\r
131 public int getPosition()
\r
133 return this._position;
\r
134 } //-- int getPosition()
\r
137 * Returns the value of field 'secondaryStructure'.
\r
140 * @return the value of field 'secondaryStructure'.
\r
142 public java.lang.String getSecondaryStructure()
\r
144 return this._secondaryStructure;
\r
145 } //-- java.lang.String getSecondaryStructure()
\r
148 * Returns the value of field 'value'.
\r
151 * @return the value of field 'value'.
\r
153 public float getValue()
\r
155 return this._value;
\r
156 } //-- float getValue()
\r
159 * Method hasPosition
\r
165 public boolean hasPosition()
\r
167 return this._has_position;
\r
168 } //-- boolean hasPosition()
\r
177 public boolean hasValue()
\r
179 return this._has_value;
\r
180 } //-- boolean hasValue()
\r
189 public boolean isValid()
\r
194 catch (org.exolab.castor.xml.ValidationException vex) {
\r
198 } //-- boolean isValid()
\r
207 public void marshal(java.io.Writer out)
\r
208 throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException
\r
211 Marshaller.marshal(this, out);
\r
212 } //-- void marshal(java.io.Writer)
\r
221 public void marshal(org.xml.sax.ContentHandler handler)
\r
222 throws java.io.IOException, org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException
\r
225 Marshaller.marshal(this, handler);
\r
226 } //-- void marshal(org.xml.sax.ContentHandler)
\r
229 * Sets the value of field 'description'.
\r
231 * @param description the value of field 'description'.
\r
233 public void setDescription(java.lang.String description)
\r
235 this._description = description;
\r
236 } //-- void setDescription(java.lang.String)
\r
239 * Sets the value of field 'displayCharacter'.
\r
241 * @param displayCharacter the value of field 'displayCharacter'
\r
243 public void setDisplayCharacter(java.lang.String displayCharacter)
\r
245 this._displayCharacter = displayCharacter;
\r
246 } //-- void setDisplayCharacter(java.lang.String)
\r
249 * Sets the value of field 'position'.
\r
251 * @param position the value of field 'position'.
\r
253 public void setPosition(int position)
\r
255 this._position = position;
\r
256 this._has_position = true;
\r
257 } //-- void setPosition(int)
\r
260 * Sets the value of field 'secondaryStructure'.
\r
262 * @param secondaryStructure the value of field
\r
263 * 'secondaryStructure'.
\r
265 public void setSecondaryStructure(java.lang.String secondaryStructure)
\r
267 this._secondaryStructure = secondaryStructure;
\r
268 } //-- void setSecondaryStructure(java.lang.String)
\r
271 * Sets the value of field 'value'.
\r
273 * @param value the value of field 'value'.
\r
275 public void setValue(float value)
\r
277 this._value = value;
\r
278 this._has_value = true;
\r
279 } //-- void setValue(float)
\r
289 public static java.lang.Object unmarshal(java.io.Reader reader)
\r
290 throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException
\r
292 return (jalview.binding.AnnotationElement) Unmarshaller.unmarshal(jalview.binding.AnnotationElement.class, reader);
\r
293 } //-- java.lang.Object unmarshal(java.io.Reader)
\r
299 public void validate()
\r
300 throws org.exolab.castor.xml.ValidationException
\r
302 org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
\r
303 validator.validate(this);
\r
304 } //-- void validate()
\r