|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Feature
Feature interface. Features implement Comparable and thus must implement a compareTo() method. This is required to maintain the sorting of Features in Tracks.
Method Summary | |
---|---|
int |
compareTo(java.lang.Object o)
Compares this object with the specified object for order. |
boolean |
contains(Feature feature)
Returns 'true' if the Feature 'feature' exists in this Feature. |
int |
contains(int pos)
Returns '-1' if this Feature exists after the integer 'pos', returns '0' if 'pos' is contained in this Feature, and '1' if 'pos' occurs after this Feature. |
boolean |
containsAttribute(java.lang.String key)
Returns true if attribute 'key' exists. |
boolean |
equals(java.lang.Object o)
This will return true if the features are equal and the sources are the same. |
Feature |
flip()
Inverts the positions, returning a new Feature object. |
java.lang.String |
getAttribute(java.lang.String key)
Get value for attribute 'key'. |
java.lang.String |
getAttributes()
Get the Feature attributes. |
java.util.HashMap |
getAttributesMap()
Get the Feature attributes as HashMap. |
java.lang.String |
getData()
Returns the underlying sequence data. |
java.lang.String |
getDataFormatted()
Returns the Sequence data, with "\n" inserted every Sequence.FORMAT_WIDTH characters (usually 50 to 80 chars). |
int |
getMax()
Returns the maximum position of the Feature. |
int |
getMin()
Returns the initial position of the Feature. |
Sequence |
getSource()
Returns the underlying Sequence object. |
java.lang.String |
getSourceID()
Returns the underlying Sequence object's ID. |
int |
getStart()
Returns the start position of the Feature. |
int |
getStop()
Returns the maximum position of the Feature. |
int |
length()
Returns the number of positions contained in the Feature. |
Feature |
overlap(Feature feature)
Returns the overlapping region between the two Features. |
boolean |
overlaps(Feature feature)
Returns 'true' if the Feature 'feature' has at least one position that overlaps positions in this Feature. |
void |
setAttributes(java.util.HashMap attribMap)
Set the Feature attributes from a HashMap. |
void |
setAttributes(java.lang.String attributes)
Set the Feature attributes. |
java.lang.String |
toString()
Only returns basic Feature information. |
java.lang.String |
toStringFull()
Returns all Feature information, except the data. |
java.lang.String |
toStringMin()
Only returns Feature start/stop information. |
Method Detail |
---|
void setAttributes(java.lang.String attributes)
void setAttributes(java.util.HashMap attribMap)
java.lang.String getAttributes()
boolean containsAttribute(java.lang.String key)
java.util.HashMap getAttributesMap()
java.lang.String getAttribute(java.lang.String key)
int getStart()
int getStop()
int length()
int getMin()
int getMax()
Sequence getSource()
java.lang.String getSourceID()
java.lang.String getData()
java.lang.String getDataFormatted()
int compareTo(java.lang.Object o)
compareTo
in interface java.lang.Comparable
boolean equals(java.lang.Object o)
equals
in class java.lang.Object
int contains(int pos)
boolean contains(Feature feature)
boolean overlaps(Feature feature)
Feature overlap(Feature feature)
Feature flip()
java.lang.String toString()
toString
in class java.lang.Object
java.lang.String toStringMin()
java.lang.String toStringFull()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |