/*
* This class was automatically generated with
- * <a href="http://www.castor.org">Castor 0.9.9M1</a>, using an XML
+ * <a href="http://www.castor.org">Castor 0.9.9M2</a>, using an XML
* Schema.
* $Id$
*/
//--------------------------/
/**
- * Field _gapChar
+ * Field _id
*/
- private java.lang.String _gapChar;
-
- /**
- * Field _aligned
- */
- private boolean _aligned;
-
- /**
- * keeps track of state for field: _aligned
- */
- private boolean _has_aligned;
+ private java.lang.String _id;
/**
* Field _sequenceList
private java.util.Vector _alignmentList;
/**
- * Field _tree
+ * Field _treeList
*/
- private org.vamsas.objects.core.Tree _tree;
+ private java.util.Vector _treeList;
/**
* Field _provenance
_sequenceList = new Vector();
_sequenceSetAnnotationsList = new Vector();
_alignmentList = new Vector();
+ _treeList = new Vector();
} //-- org.vamsas.objects.core.SequenceSet()
} //-- void addSequenceSetAnnotations(int, org.vamsas.objects.core.SequenceSetAnnotations)
/**
- * Method deleteAligned
+ * Method addTree
+ *
+ *
+ *
+ * @param vTree
+ */
+ public void addTree(org.vamsas.objects.core.Tree vTree)
+ throws java.lang.IndexOutOfBoundsException
+ {
+ _treeList.addElement(vTree);
+ } //-- void addTree(org.vamsas.objects.core.Tree)
+
+ /**
+ * Method addTree
+ *
*
+ *
+ * @param index
+ * @param vTree
*/
- public void deleteAligned()
+ public void addTree(int index, org.vamsas.objects.core.Tree vTree)
+ throws java.lang.IndexOutOfBoundsException
{
- this._has_aligned= false;
- } //-- void deleteAligned()
+ _treeList.insertElementAt(vTree, index);
+ } //-- void addTree(int, org.vamsas.objects.core.Tree)
/**
* Method enumerateAlignment
} //-- java.util.Enumeration enumerateSequenceSetAnnotations()
/**
+ * Method enumerateTree
+ *
+ *
+ *
+ * @return Enumeration
+ */
+ public java.util.Enumeration enumerateTree()
+ {
+ return _treeList.elements();
+ } //-- java.util.Enumeration enumerateTree()
+
+ /**
* Note: hashCode() has not been overriden
*
* @param obj
if (obj instanceof SequenceSet) {
SequenceSet temp = (SequenceSet)obj;
- if (this._gapChar != null) {
- if (temp._gapChar == null) return false;
- else if (!(this._gapChar.equals(temp._gapChar)))
+ if (this._id != null) {
+ if (temp._id == null) return false;
+ else if (!(this._id.equals(temp._id)))
return false;
}
- else if (temp._gapChar != null)
- return false;
- if (this._aligned != temp._aligned)
- return false;
- if (this._has_aligned != temp._has_aligned)
+ else if (temp._id != null)
return false;
if (this._sequenceList != null) {
if (temp._sequenceList == null) return false;
}
else if (temp._alignmentList != null)
return false;
- if (this._tree != null) {
- if (temp._tree == null) return false;
- else if (!(this._tree.equals(temp._tree)))
+ if (this._treeList != null) {
+ if (temp._treeList == null) return false;
+ else if (!(this._treeList.equals(temp._treeList)))
return false;
}
- else if (temp._tree != null)
+ else if (temp._treeList != null)
return false;
if (this._provenance != null) {
if (temp._provenance == null) return false;
} //-- boolean equals(java.lang.Object)
/**
- * Returns the value of field 'aligned'.
- *
- * @return boolean
- * @return the value of field 'aligned'.
- */
- public boolean getAligned()
- {
- return this._aligned;
- } //-- boolean getAligned()
-
- /**
* Method getAlignment
*
*
} //-- int getAlignmentCount()
/**
- * Returns the value of field 'gapChar'.
+ * Returns the value of field 'id'.
*
* @return String
- * @return the value of field 'gapChar'.
+ * @return the value of field 'id'.
*/
- public java.lang.String getGapChar()
+ public java.lang.String getId()
{
- return this._gapChar;
- } //-- java.lang.String getGapChar()
+ return this._id;
+ } //-- java.lang.String getId()
/**
* Returns the value of field 'provenance'.
} //-- int getSequenceSetAnnotationsCount()
/**
- * Returns the value of field 'tree'.
+ * Method getTree
+ *
+ *
+ *
+ * @param index
+ * @return Tree
+ */
+ public org.vamsas.objects.core.Tree getTree(int index)
+ throws java.lang.IndexOutOfBoundsException
+ {
+ //-- check bounds for index
+ if ((index < 0) || (index > _treeList.size())) {
+ throw new IndexOutOfBoundsException("getTree: Index value '"+index+"' not in range [0.."+_treeList.size()+ "]");
+ }
+
+ return (org.vamsas.objects.core.Tree) _treeList.elementAt(index);
+ } //-- org.vamsas.objects.core.Tree getTree(int)
+
+ /**
+ * Method getTree
+ *
+ *
*
* @return Tree
- * @return the value of field 'tree'.
*/
- public org.vamsas.objects.core.Tree getTree()
+ public org.vamsas.objects.core.Tree[] getTree()
{
- return this._tree;
- } //-- org.vamsas.objects.core.Tree getTree()
+ int size = _treeList.size();
+ org.vamsas.objects.core.Tree[] mArray = new org.vamsas.objects.core.Tree[size];
+ for (int index = 0; index < size; index++) {
+ mArray[index] = (org.vamsas.objects.core.Tree) _treeList.elementAt(index);
+ }
+ return mArray;
+ } //-- org.vamsas.objects.core.Tree[] getTree()
/**
- * Method hasAligned
+ * Method getTreeCount
*
*
*
- * @return boolean
+ * @return int
*/
- public boolean hasAligned()
+ public int getTreeCount()
{
- return this._has_aligned;
- } //-- boolean hasAligned()
+ return _treeList.size();
+ } //-- int getTreeCount()
/**
* Method isValid
} //-- void removeAllSequenceSetAnnotations()
/**
+ * Method removeAllTree
+ *
+ */
+ public void removeAllTree()
+ {
+ _treeList.removeAllElements();
+ } //-- void removeAllTree()
+
+ /**
* Method removeSequence
*
*
} //-- org.vamsas.objects.core.SequenceSetAnnotations removeSequenceSetAnnotations(int)
/**
- * Sets the value of field 'aligned'.
+ * Method removeTree
*
- * @param aligned the value of field 'aligned'.
+ *
+ *
+ * @param index
+ * @return Tree
*/
- public void setAligned(boolean aligned)
+ public org.vamsas.objects.core.Tree removeTree(int index)
{
- this._aligned = aligned;
- this._has_aligned = true;
- } //-- void setAligned(boolean)
+ java.lang.Object obj = _treeList.elementAt(index);
+ _treeList.removeElementAt(index);
+ return (org.vamsas.objects.core.Tree) obj;
+ } //-- org.vamsas.objects.core.Tree removeTree(int)
/**
* Method setAlignment
} //-- void setAlignment(org.vamsas.objects.core.Alignment)
/**
- * Sets the value of field 'gapChar'.
+ * Sets the value of field 'id'.
*
- * @param gapChar the value of field 'gapChar'.
+ * @param id the value of field 'id'.
*/
- public void setGapChar(java.lang.String gapChar)
+ public void setId(java.lang.String id)
{
- this._gapChar = gapChar;
- } //-- void setGapChar(java.lang.String)
+ this._id = id;
+ } //-- void setId(java.lang.String)
/**
* Sets the value of field 'provenance'.
} //-- void setSequenceSetAnnotations(org.vamsas.objects.core.SequenceSetAnnotations)
/**
- * Sets the value of field 'tree'.
+ * Method setTree
+ *
*
- * @param tree the value of field 'tree'.
+ *
+ * @param index
+ * @param vTree
*/
- public void setTree(org.vamsas.objects.core.Tree tree)
+ public void setTree(int index, org.vamsas.objects.core.Tree vTree)
+ throws java.lang.IndexOutOfBoundsException
{
- this._tree = tree;
+ //-- check bounds for index
+ if ((index < 0) || (index > _treeList.size())) {
+ throw new IndexOutOfBoundsException("setTree: Index value '"+index+"' not in range [0.."+_treeList.size()+ "]");
+ }
+ _treeList.setElementAt(vTree, index);
+ } //-- void setTree(int, org.vamsas.objects.core.Tree)
+
+ /**
+ * Method setTree
+ *
+ *
+ *
+ * @param treeArray
+ */
+ public void setTree(org.vamsas.objects.core.Tree[] treeArray)
+ {
+ //-- copy array
+ _treeList.removeAllElements();
+ for (int i = 0; i < treeArray.length; i++) {
+ _treeList.addElement(treeArray[i]);
+ }
} //-- void setTree(org.vamsas.objects.core.Tree)
/**