public interface SequenceI
{
/**
- * DOCUMENT ME!
+ * Set the display name for the sequence
*
- * @param name DOCUMENT ME!
+ * @param name
*/
public void setName(String name);
/**
- * DOCUMENT ME!
- *
- * @return DOCUMENT ME!
+ * Get the display name
*/
public String getName();
/**
- * DOCUMENT ME!
+ * Set start position of first non-gapped symbol in sequence
*
- * @param start DOCUMENT ME!
+ * @param start new start position
*/
public void setStart(int start);
/**
- * DOCUMENT ME!
- *
- * @return DOCUMENT ME!
+ * get start position of first non-gapped residue in sequence
+ * @return
*/
public int getStart();
/**
- * DOCUMENT ME!
- *
- * @return DOCUMENT ME!
+ * get the displayed id of the sequence
+ * @return true means the id will be returned in the form DisplayName/Start-End
*/
public String getDisplayId(boolean jvsuffix);
/**
- * DOCUMENT ME!
- *
- * @param end DOCUMENT ME!
+ * set end position for last residue in sequence
+ * @param end
*/
public void setEnd(int end);
/**
- * DOCUMENT ME!
+ * get end position for last residue in sequence
+ * getEnd()>getStart() unless sequence only consists of gap characters
*
- * @return DOCUMENT ME!
+ * @return
*/
public int getEnd();
/**
- * DOCUMENT ME!
- *
- * @return DOCUMENT ME!
+ * @return length of sequence including gaps
+
*/
public int getLength();
/**
- * DOCUMENT ME!
+ * Replace the sequence with the given string
*
- * @param sequence DOCUMENT ME!
+ * @param sequence new sequence string
*/
public void setSequence(String sequence);
/**
- * DOCUMENT ME!
- *
- * @return DOCUMENT ME!
+ * @return sequence as string
*/
public String getSequenceAsString();
/**
- * DOCUMENT ME!
- *
+ * get a range on the seuqence as a string
* @param start DOCUMENT ME!
* @param end DOCUMENT ME!
*
public char[] getSequence();
/**
- * DOCUMENT ME!
+ * get stretch of sequence characters in an array
*
- * @param start DOCUMENT ME!
- * @param end DOCUMENT ME!
+ * @param start absolute index into getSequence()
+ * @param end exclusive index of last position in segment to be returned.
*
- * @return DOCUMENT ME!
+ * @return char[max(0,end-start)];
*/
public char[] getSequence(int start, int end);
public int[] gapMap();
/**
+ * Returns an int array where indices correspond to each position in
+ * sequence char array and the element value gives the result of findPosition
+ * for that index in the sequence.
+ *
+ * @return int[SequenceI.getLength()]
+ */
+ public int[] findPositionMap();
+ /**
* Delete a range of aligned sequence columns, creating a new dataset sequence if necessary
* and adjusting start and end positions accordingly.
*
*/
public Vector getPDBId();
+ /**
+ * add entry to the vector of PDBIds, if it isn't in the list already
+ * @param entry
+ */
public void addPDBId(PDBEntry entry);
+ /**
+ * update the list of PDBEntrys to include any DBRefEntrys citing structural databases
+ * @return true if PDBEntry list was modified
+ */
+ public boolean updatePDBIds();
public String getVamsasId();
* @return dataset sequence for this sequence
*/
public SequenceI createDatasetSequence();
+
+ /**
+ * Transfer any database references or annotation from entry
+ * under a sequence mapping.
+ * @param entry
+ * @param mp null or mapping from entry's numbering to local start/end
+ */
+ public void transferAnnotation(SequenceI entry, Mapping mp);
}