2 * This class was automatically generated with
\r
3 * <a href="http://www.castor.org">Castor 0.9.9M2</a>, using an XML
\r
8 package org.vamsas.objects.core;
\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 java.util.Enumeration;
\r
19 import java.util.Vector;
\r
20 import org.exolab.castor.xml.MarshalException;
\r
21 import org.exolab.castor.xml.Marshaller;
\r
22 import org.exolab.castor.xml.Unmarshaller;
\r
23 import org.exolab.castor.xml.ValidationException;
\r
24 import org.xml.sax.ContentHandler;
\r
27 * Annotation for a rangeSpec - values can be attached for the
\r
28 * whole specification, and to each position within the spec.
\r
29 * following the orientation specified by the ordered set of
\r
30 * rangeSpec (pos, seg) elements.
\r
33 * @version $Revision$ $Date$
\r
35 public class RangeAnnotation extends org.vamsas.objects.core.RangeType
\r
36 implements java.io.Serializable
\r
40 //--------------------------/
\r
41 //- Class/Member Variables -/
\r
42 //--------------------------/
\r
45 * Primary Key for vamsas object referencing
\r
48 private java.lang.String _id;
\r
51 * objects with modifiable=false will not be
\r
52 * modified by a vamsas client update
\r
55 private boolean _modifiable = true;
\r
58 * keeps track of state for field: _modifiable
\r
60 private boolean _has_modifiable;
\r
63 * Annotation with the same non-empty group
\r
64 * name are grouped together
\r
67 private java.lang.String _group = "";
\r
70 * A Das Feature has both a type and a Type ID.
\r
71 * We go the route of requiring the type string
\r
72 * to be taken from a controlled vocabulary if
\r
73 * an application expects others to make sense
\r
75 * The type may qualified - so uniprot:CHAIN is a valid type
\r
77 * and considered distinct from someotherDB:CHAIN
\r
80 private java.lang.String _type;
\r
83 * Short, meaningful name for the annotation - if this is
\r
84 * absent, then the type string should be used in its place.
\r
87 private java.lang.String _label;
\r
90 * Human readable description of the annotation
\r
93 private java.lang.String _description;
\r
96 * TODO: specify this - we have considered taking the GO
\r
97 * evidence codes as a model for assessing a measure of quality
\r
101 private java.lang.String _status;
\r
104 * Annotation Element position maps to
\r
105 * ordered positions defined by the
\r
106 * sequence of rangeType pos positions or
\r
107 * concatenated seg start/end segments.
\r
110 private java.util.Vector _annotationElementList;
\r
113 * Ordered set of optionally named float
\r
114 * values for the whole annotation
\r
117 private java.util.Vector _scoreList;
\r
122 private java.util.Vector _linkList;
\r
125 * Note:These are mutable so an application
\r
126 * should check them each time.
\r
129 private java.util.Vector _propertyList;
\r
132 //----------------/
\r
133 //- Constructors -/
\r
134 //----------------/
\r
136 public RangeAnnotation()
\r
140 _annotationElementList = new Vector();
\r
141 _scoreList = new Vector();
\r
142 _linkList = new Vector();
\r
143 _propertyList = new Vector();
\r
144 } //-- org.vamsas.objects.core.RangeAnnotation()
\r
152 * Method addAnnotationElement
\r
156 * @param vAnnotationElement
\r
158 public void addAnnotationElement(org.vamsas.objects.core.AnnotationElement vAnnotationElement)
\r
159 throws java.lang.IndexOutOfBoundsException
\r
161 _annotationElementList.addElement(vAnnotationElement);
\r
162 } //-- void addAnnotationElement(org.vamsas.objects.core.AnnotationElement)
\r
165 * Method addAnnotationElement
\r
170 * @param vAnnotationElement
\r
172 public void addAnnotationElement(int index, org.vamsas.objects.core.AnnotationElement vAnnotationElement)
\r
173 throws java.lang.IndexOutOfBoundsException
\r
175 _annotationElementList.insertElementAt(vAnnotationElement, index);
\r
176 } //-- void addAnnotationElement(int, org.vamsas.objects.core.AnnotationElement)
\r
185 public void addLink(org.vamsas.objects.core.Link vLink)
\r
186 throws java.lang.IndexOutOfBoundsException
\r
188 _linkList.addElement(vLink);
\r
189 } //-- void addLink(org.vamsas.objects.core.Link)
\r
199 public void addLink(int index, org.vamsas.objects.core.Link vLink)
\r
200 throws java.lang.IndexOutOfBoundsException
\r
202 _linkList.insertElementAt(vLink, index);
\r
203 } //-- void addLink(int, org.vamsas.objects.core.Link)
\r
206 * Method addProperty
\r
212 public void addProperty(org.vamsas.objects.core.Property vProperty)
\r
213 throws java.lang.IndexOutOfBoundsException
\r
215 _propertyList.addElement(vProperty);
\r
216 } //-- void addProperty(org.vamsas.objects.core.Property)
\r
219 * Method addProperty
\r
226 public void addProperty(int index, org.vamsas.objects.core.Property vProperty)
\r
227 throws java.lang.IndexOutOfBoundsException
\r
229 _propertyList.insertElementAt(vProperty, index);
\r
230 } //-- void addProperty(int, org.vamsas.objects.core.Property)
\r
239 public void addScore(org.vamsas.objects.core.Score vScore)
\r
240 throws java.lang.IndexOutOfBoundsException
\r
242 _scoreList.addElement(vScore);
\r
243 } //-- void addScore(org.vamsas.objects.core.Score)
\r
253 public void addScore(int index, org.vamsas.objects.core.Score vScore)
\r
254 throws java.lang.IndexOutOfBoundsException
\r
256 _scoreList.insertElementAt(vScore, index);
\r
257 } //-- void addScore(int, org.vamsas.objects.core.Score)
\r
260 * Method deleteModifiable
\r
263 public void deleteModifiable()
\r
265 this._has_modifiable= false;
\r
266 } //-- void deleteModifiable()
\r
269 * Method enumerateAnnotationElement
\r
273 * @return Enumeration
\r
275 public java.util.Enumeration enumerateAnnotationElement()
\r
277 return _annotationElementList.elements();
\r
278 } //-- java.util.Enumeration enumerateAnnotationElement()
\r
281 * Method enumerateLink
\r
285 * @return Enumeration
\r
287 public java.util.Enumeration enumerateLink()
\r
289 return _linkList.elements();
\r
290 } //-- java.util.Enumeration enumerateLink()
\r
293 * Method enumerateProperty
\r
297 * @return Enumeration
\r
299 public java.util.Enumeration enumerateProperty()
\r
301 return _propertyList.elements();
\r
302 } //-- java.util.Enumeration enumerateProperty()
\r
305 * Method enumerateScore
\r
309 * @return Enumeration
\r
311 public java.util.Enumeration enumerateScore()
\r
313 return _scoreList.elements();
\r
314 } //-- java.util.Enumeration enumerateScore()
\r
317 * Note: hashCode() has not been overriden
\r
322 public boolean equals(java.lang.Object obj)
\r
327 if (super.equals(obj)==false)
\r
330 if (obj instanceof RangeAnnotation) {
\r
332 RangeAnnotation temp = (RangeAnnotation)obj;
\r
333 if (this._id != null) {
\r
334 if (temp._id == null) return false;
\r
335 else if (!(this._id.equals(temp._id)))
\r
338 else if (temp._id != null)
\r
340 if (this._modifiable != temp._modifiable)
\r
342 if (this._has_modifiable != temp._has_modifiable)
\r
344 if (this._group != null) {
\r
345 if (temp._group == null) return false;
\r
346 else if (!(this._group.equals(temp._group)))
\r
349 else if (temp._group != null)
\r
351 if (this._type != null) {
\r
352 if (temp._type == null) return false;
\r
353 else if (!(this._type.equals(temp._type)))
\r
356 else if (temp._type != null)
\r
358 if (this._label != null) {
\r
359 if (temp._label == null) return false;
\r
360 else if (!(this._label.equals(temp._label)))
\r
363 else if (temp._label != null)
\r
365 if (this._description != null) {
\r
366 if (temp._description == null) return false;
\r
367 else if (!(this._description.equals(temp._description)))
\r
370 else if (temp._description != null)
\r
372 if (this._status != null) {
\r
373 if (temp._status == null) return false;
\r
374 else if (!(this._status.equals(temp._status)))
\r
377 else if (temp._status != null)
\r
379 if (this._annotationElementList != null) {
\r
380 if (temp._annotationElementList == null) return false;
\r
381 else if (!(this._annotationElementList.equals(temp._annotationElementList)))
\r
384 else if (temp._annotationElementList != null)
\r
386 if (this._scoreList != null) {
\r
387 if (temp._scoreList == null) return false;
\r
388 else if (!(this._scoreList.equals(temp._scoreList)))
\r
391 else if (temp._scoreList != null)
\r
393 if (this._linkList != null) {
\r
394 if (temp._linkList == null) return false;
\r
395 else if (!(this._linkList.equals(temp._linkList)))
\r
398 else if (temp._linkList != null)
\r
400 if (this._propertyList != null) {
\r
401 if (temp._propertyList == null) return false;
\r
402 else if (!(this._propertyList.equals(temp._propertyList)))
\r
405 else if (temp._propertyList != null)
\r
410 } //-- boolean equals(java.lang.Object)
\r
413 * Method getAnnotationElement
\r
418 * @return AnnotationElement
\r
420 public org.vamsas.objects.core.AnnotationElement getAnnotationElement(int index)
\r
421 throws java.lang.IndexOutOfBoundsException
\r
423 //-- check bounds for index
\r
424 if ((index < 0) || (index > _annotationElementList.size())) {
\r
425 throw new IndexOutOfBoundsException("getAnnotationElement: Index value '"+index+"' not in range [0.."+_annotationElementList.size()+ "]");
\r
428 return (org.vamsas.objects.core.AnnotationElement) _annotationElementList.elementAt(index);
\r
429 } //-- org.vamsas.objects.core.AnnotationElement getAnnotationElement(int)
\r
432 * Method getAnnotationElement
\r
436 * @return AnnotationElement
\r
438 public org.vamsas.objects.core.AnnotationElement[] getAnnotationElement()
\r
440 int size = _annotationElementList.size();
\r
441 org.vamsas.objects.core.AnnotationElement[] mArray = new org.vamsas.objects.core.AnnotationElement[size];
\r
442 for (int index = 0; index < size; index++) {
\r
443 mArray[index] = (org.vamsas.objects.core.AnnotationElement) _annotationElementList.elementAt(index);
\r
446 } //-- org.vamsas.objects.core.AnnotationElement[] getAnnotationElement()
\r
449 * Method getAnnotationElementCount
\r
455 public int getAnnotationElementCount()
\r
457 return _annotationElementList.size();
\r
458 } //-- int getAnnotationElementCount()
\r
461 * Returns the value of field 'description'. The field
\r
462 * 'description' has the following description: Human readable
\r
463 * description of the annotation
\r
467 * @return the value of field 'description'.
\r
469 public java.lang.String getDescription()
\r
471 return this._description;
\r
472 } //-- java.lang.String getDescription()
\r
475 * Returns the value of field 'group'. The field 'group' has
\r
476 * the following description: Annotation with the same
\r
478 * name are grouped together
\r
482 * @return the value of field 'group'.
\r
484 public java.lang.String getGroup()
\r
486 return this._group;
\r
487 } //-- java.lang.String getGroup()
\r
490 * Returns the value of field 'id'. The field 'id' has the
\r
491 * following description: Primary Key for vamsas object
\r
496 * @return the value of field 'id'.
\r
498 public java.lang.String getId()
\r
501 } //-- java.lang.String getId()
\r
504 * Returns the value of field 'label'. The field 'label' has
\r
505 * the following description: Short, meaningful name for the
\r
506 * annotation - if this is absent, then the type string should
\r
507 * be used in its place.
\r
511 * @return the value of field 'label'.
\r
513 public java.lang.String getLabel()
\r
515 return this._label;
\r
516 } //-- java.lang.String getLabel()
\r
526 public org.vamsas.objects.core.Link getLink(int index)
\r
527 throws java.lang.IndexOutOfBoundsException
\r
529 //-- check bounds for index
\r
530 if ((index < 0) || (index > _linkList.size())) {
\r
531 throw new IndexOutOfBoundsException("getLink: Index value '"+index+"' not in range [0.."+_linkList.size()+ "]");
\r
534 return (org.vamsas.objects.core.Link) _linkList.elementAt(index);
\r
535 } //-- org.vamsas.objects.core.Link getLink(int)
\r
544 public org.vamsas.objects.core.Link[] getLink()
\r
546 int size = _linkList.size();
\r
547 org.vamsas.objects.core.Link[] mArray = new org.vamsas.objects.core.Link[size];
\r
548 for (int index = 0; index < size; index++) {
\r
549 mArray[index] = (org.vamsas.objects.core.Link) _linkList.elementAt(index);
\r
552 } //-- org.vamsas.objects.core.Link[] getLink()
\r
555 * Method getLinkCount
\r
561 public int getLinkCount()
\r
563 return _linkList.size();
\r
564 } //-- int getLinkCount()
\r
567 * Returns the value of field 'modifiable'. The field
\r
568 * 'modifiable' has the following description: objects with
\r
569 * modifiable=false will not be
\r
570 * modified by a vamsas client update
\r
574 * @return the value of field 'modifiable'.
\r
576 public boolean getModifiable()
\r
578 return this._modifiable;
\r
579 } //-- boolean getModifiable()
\r
582 * Method getProperty
\r
589 public org.vamsas.objects.core.Property getProperty(int index)
\r
590 throws java.lang.IndexOutOfBoundsException
\r
592 //-- check bounds for index
\r
593 if ((index < 0) || (index > _propertyList.size())) {
\r
594 throw new IndexOutOfBoundsException("getProperty: Index value '"+index+"' not in range [0.."+_propertyList.size()+ "]");
\r
597 return (org.vamsas.objects.core.Property) _propertyList.elementAt(index);
\r
598 } //-- org.vamsas.objects.core.Property getProperty(int)
\r
601 * Method getProperty
\r
607 public org.vamsas.objects.core.Property[] getProperty()
\r
609 int size = _propertyList.size();
\r
610 org.vamsas.objects.core.Property[] mArray = new org.vamsas.objects.core.Property[size];
\r
611 for (int index = 0; index < size; index++) {
\r
612 mArray[index] = (org.vamsas.objects.core.Property) _propertyList.elementAt(index);
\r
615 } //-- org.vamsas.objects.core.Property[] getProperty()
\r
618 * Method getPropertyCount
\r
624 public int getPropertyCount()
\r
626 return _propertyList.size();
\r
627 } //-- int getPropertyCount()
\r
637 public org.vamsas.objects.core.Score getScore(int index)
\r
638 throws java.lang.IndexOutOfBoundsException
\r
640 //-- check bounds for index
\r
641 if ((index < 0) || (index > _scoreList.size())) {
\r
642 throw new IndexOutOfBoundsException("getScore: Index value '"+index+"' not in range [0.."+_scoreList.size()+ "]");
\r
645 return (org.vamsas.objects.core.Score) _scoreList.elementAt(index);
\r
646 } //-- org.vamsas.objects.core.Score getScore(int)
\r
655 public org.vamsas.objects.core.Score[] getScore()
\r
657 int size = _scoreList.size();
\r
658 org.vamsas.objects.core.Score[] mArray = new org.vamsas.objects.core.Score[size];
\r
659 for (int index = 0; index < size; index++) {
\r
660 mArray[index] = (org.vamsas.objects.core.Score) _scoreList.elementAt(index);
\r
663 } //-- org.vamsas.objects.core.Score[] getScore()
\r
666 * Method getScoreCount
\r
672 public int getScoreCount()
\r
674 return _scoreList.size();
\r
675 } //-- int getScoreCount()
\r
678 * Returns the value of field 'status'. The field 'status' has
\r
679 * the following description: TODO: specify this - we have
\r
680 * considered taking the GO evidence codes as a model for
\r
681 * assessing a measure of quality to an annotation.
\r
685 * @return the value of field 'status'.
\r
687 public java.lang.String getStatus()
\r
689 return this._status;
\r
690 } //-- java.lang.String getStatus()
\r
693 * Returns the value of field 'type'. The field 'type' has the
\r
694 * following description: A Das Feature has both a type and a
\r
696 * We go the route of requiring the type string
\r
697 * to be taken from a controlled vocabulary if
\r
698 * an application expects others to make sense
\r
700 * The type may qualified - so uniprot:CHAIN is a valid type
\r
702 * and considered distinct from someotherDB:CHAIN
\r
706 * @return the value of field 'type'.
\r
708 public java.lang.String getType()
\r
711 } //-- java.lang.String getType()
\r
714 * Method hasModifiable
\r
720 public boolean hasModifiable()
\r
722 return this._has_modifiable;
\r
723 } //-- boolean hasModifiable()
\r
732 public boolean isValid()
\r
737 catch (org.exolab.castor.xml.ValidationException vex) {
\r
741 } //-- boolean isValid()
\r
750 public void marshal(java.io.Writer out)
\r
751 throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException
\r
754 Marshaller.marshal(this, out);
\r
755 } //-- void marshal(java.io.Writer)
\r
764 public void marshal(org.xml.sax.ContentHandler handler)
\r
765 throws java.io.IOException, org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException
\r
768 Marshaller.marshal(this, handler);
\r
769 } //-- void marshal(org.xml.sax.ContentHandler)
\r
772 * Method removeAllAnnotationElement
\r
775 public void removeAllAnnotationElement()
\r
777 _annotationElementList.removeAllElements();
\r
778 } //-- void removeAllAnnotationElement()
\r
781 * Method removeAllLink
\r
784 public void removeAllLink()
\r
786 _linkList.removeAllElements();
\r
787 } //-- void removeAllLink()
\r
790 * Method removeAllProperty
\r
793 public void removeAllProperty()
\r
795 _propertyList.removeAllElements();
\r
796 } //-- void removeAllProperty()
\r
799 * Method removeAllScore
\r
802 public void removeAllScore()
\r
804 _scoreList.removeAllElements();
\r
805 } //-- void removeAllScore()
\r
808 * Method removeAnnotationElement
\r
813 * @return AnnotationElement
\r
815 public org.vamsas.objects.core.AnnotationElement removeAnnotationElement(int index)
\r
817 java.lang.Object obj = _annotationElementList.elementAt(index);
\r
818 _annotationElementList.removeElementAt(index);
\r
819 return (org.vamsas.objects.core.AnnotationElement) obj;
\r
820 } //-- org.vamsas.objects.core.AnnotationElement removeAnnotationElement(int)
\r
823 * Method removeLink
\r
830 public org.vamsas.objects.core.Link removeLink(int index)
\r
832 java.lang.Object obj = _linkList.elementAt(index);
\r
833 _linkList.removeElementAt(index);
\r
834 return (org.vamsas.objects.core.Link) obj;
\r
835 } //-- org.vamsas.objects.core.Link removeLink(int)
\r
838 * Method removeProperty
\r
845 public org.vamsas.objects.core.Property removeProperty(int index)
\r
847 java.lang.Object obj = _propertyList.elementAt(index);
\r
848 _propertyList.removeElementAt(index);
\r
849 return (org.vamsas.objects.core.Property) obj;
\r
850 } //-- org.vamsas.objects.core.Property removeProperty(int)
\r
853 * Method removeScore
\r
860 public org.vamsas.objects.core.Score removeScore(int index)
\r
862 java.lang.Object obj = _scoreList.elementAt(index);
\r
863 _scoreList.removeElementAt(index);
\r
864 return (org.vamsas.objects.core.Score) obj;
\r
865 } //-- org.vamsas.objects.core.Score removeScore(int)
\r
868 * Method setAnnotationElement
\r
873 * @param vAnnotationElement
\r
875 public void setAnnotationElement(int index, org.vamsas.objects.core.AnnotationElement vAnnotationElement)
\r
876 throws java.lang.IndexOutOfBoundsException
\r
878 //-- check bounds for index
\r
879 if ((index < 0) || (index > _annotationElementList.size())) {
\r
880 throw new IndexOutOfBoundsException("setAnnotationElement: Index value '"+index+"' not in range [0.."+_annotationElementList.size()+ "]");
\r
882 _annotationElementList.setElementAt(vAnnotationElement, index);
\r
883 } //-- void setAnnotationElement(int, org.vamsas.objects.core.AnnotationElement)
\r
886 * Method setAnnotationElement
\r
890 * @param annotationElementArray
\r
892 public void setAnnotationElement(org.vamsas.objects.core.AnnotationElement[] annotationElementArray)
\r
895 _annotationElementList.removeAllElements();
\r
896 for (int i = 0; i < annotationElementArray.length; i++) {
\r
897 _annotationElementList.addElement(annotationElementArray[i]);
\r
899 } //-- void setAnnotationElement(org.vamsas.objects.core.AnnotationElement)
\r
902 * Sets the value of field 'description'. The field
\r
903 * 'description' has the following description: Human readable
\r
904 * description of the annotation
\r
907 * @param description the value of field 'description'.
\r
909 public void setDescription(java.lang.String description)
\r
911 this._description = description;
\r
912 } //-- void setDescription(java.lang.String)
\r
915 * Sets the value of field 'group'. The field 'group' has the
\r
916 * following description: Annotation with the same non-empty
\r
918 * name are grouped together
\r
921 * @param group the value of field 'group'.
\r
923 public void setGroup(java.lang.String group)
\r
925 this._group = group;
\r
926 } //-- void setGroup(java.lang.String)
\r
929 * Sets the value of field 'id'. The field 'id' has the
\r
930 * following description: Primary Key for vamsas object
\r
934 * @param id the value of field 'id'.
\r
936 public void setId(java.lang.String id)
\r
939 } //-- void setId(java.lang.String)
\r
942 * Sets the value of field 'label'. The field 'label' has the
\r
943 * following description: Short, meaningful name for the
\r
944 * annotation - if this is absent, then the type string should
\r
945 * be used in its place.
\r
948 * @param label the value of field 'label'.
\r
950 public void setLabel(java.lang.String label)
\r
952 this._label = label;
\r
953 } //-- void setLabel(java.lang.String)
\r
963 public void setLink(int index, org.vamsas.objects.core.Link vLink)
\r
964 throws java.lang.IndexOutOfBoundsException
\r
966 //-- check bounds for index
\r
967 if ((index < 0) || (index > _linkList.size())) {
\r
968 throw new IndexOutOfBoundsException("setLink: Index value '"+index+"' not in range [0.."+_linkList.size()+ "]");
\r
970 _linkList.setElementAt(vLink, index);
\r
971 } //-- void setLink(int, org.vamsas.objects.core.Link)
\r
980 public void setLink(org.vamsas.objects.core.Link[] linkArray)
\r
983 _linkList.removeAllElements();
\r
984 for (int i = 0; i < linkArray.length; i++) {
\r
985 _linkList.addElement(linkArray[i]);
\r
987 } //-- void setLink(org.vamsas.objects.core.Link)
\r
990 * Sets the value of field 'modifiable'. The field 'modifiable'
\r
991 * has the following description: objects with modifiable=false
\r
993 * modified by a vamsas client update
\r
996 * @param modifiable the value of field 'modifiable'.
\r
998 public void setModifiable(boolean modifiable)
\r
1000 this._modifiable = modifiable;
\r
1001 this._has_modifiable = true;
\r
1002 } //-- void setModifiable(boolean)
\r
1005 * Method setProperty
\r
1010 * @param vProperty
\r
1012 public void setProperty(int index, org.vamsas.objects.core.Property vProperty)
\r
1013 throws java.lang.IndexOutOfBoundsException
\r
1015 //-- check bounds for index
\r
1016 if ((index < 0) || (index > _propertyList.size())) {
\r
1017 throw new IndexOutOfBoundsException("setProperty: Index value '"+index+"' not in range [0.."+_propertyList.size()+ "]");
\r
1019 _propertyList.setElementAt(vProperty, index);
\r
1020 } //-- void setProperty(int, org.vamsas.objects.core.Property)
\r
1023 * Method setProperty
\r
1027 * @param propertyArray
\r
1029 public void setProperty(org.vamsas.objects.core.Property[] propertyArray)
\r
1032 _propertyList.removeAllElements();
\r
1033 for (int i = 0; i < propertyArray.length; i++) {
\r
1034 _propertyList.addElement(propertyArray[i]);
\r
1036 } //-- void setProperty(org.vamsas.objects.core.Property)
\r
1046 public void setScore(int index, org.vamsas.objects.core.Score vScore)
\r
1047 throws java.lang.IndexOutOfBoundsException
\r
1049 //-- check bounds for index
\r
1050 if ((index < 0) || (index > _scoreList.size())) {
\r
1051 throw new IndexOutOfBoundsException("setScore: Index value '"+index+"' not in range [0.."+_scoreList.size()+ "]");
\r
1053 _scoreList.setElementAt(vScore, index);
\r
1054 } //-- void setScore(int, org.vamsas.objects.core.Score)
\r
1061 * @param scoreArray
\r
1063 public void setScore(org.vamsas.objects.core.Score[] scoreArray)
\r
1066 _scoreList.removeAllElements();
\r
1067 for (int i = 0; i < scoreArray.length; i++) {
\r
1068 _scoreList.addElement(scoreArray[i]);
\r
1070 } //-- void setScore(org.vamsas.objects.core.Score)
\r
1073 * Sets the value of field 'status'. The field 'status' has the
\r
1074 * following description: TODO: specify this - we have
\r
1075 * considered taking the GO evidence codes as a model for
\r
1076 * assessing a measure of quality to an annotation.
\r
1079 * @param status the value of field 'status'.
\r
1081 public void setStatus(java.lang.String status)
\r
1083 this._status = status;
\r
1084 } //-- void setStatus(java.lang.String)
\r
1087 * Sets the value of field 'type'. The field 'type' has the
\r
1088 * following description: A Das Feature has both a type and a
\r
1090 * We go the route of requiring the type string
\r
1091 * to be taken from a controlled vocabulary if
\r
1092 * an application expects others to make sense
\r
1094 * The type may qualified - so uniprot:CHAIN is a valid type
\r
1096 * and considered distinct from someotherDB:CHAIN
\r
1099 * @param type the value of field 'type'.
\r
1101 public void setType(java.lang.String type)
\r
1103 this._type = type;
\r
1104 } //-- void setType(java.lang.String)
\r
1107 * Method unmarshal
\r
1112 * @return RangeType
\r
1114 public static org.vamsas.objects.core.RangeType unmarshal(java.io.Reader reader)
\r
1115 throws org.exolab.castor.xml.MarshalException, org.exolab.castor.xml.ValidationException
\r
1117 return (org.vamsas.objects.core.RangeAnnotation) Unmarshaller.unmarshal(org.vamsas.objects.core.RangeAnnotation.class, reader);
\r
1118 } //-- org.vamsas.objects.core.RangeType unmarshal(java.io.Reader)
\r
1124 public void validate()
\r
1125 throws org.exolab.castor.xml.ValidationException
\r
1127 org.exolab.castor.xml.Validator validator = new org.exolab.castor.xml.Validator();
\r
1128 validator.validate(this);
\r
1129 } //-- void validate()
\r