public class NonOverlappingIntervalList extends TreeSet<SimpleSequenceInterval>
SequenceIntervalList
,
Serialized FormConstructor and Description |
---|
NonOverlappingIntervalList() |
Modifier and Type | Method and Description |
---|---|
boolean |
add(int pos) |
boolean |
add(int firstPos,
int lastPos) |
boolean |
add(SimpleSequenceInterval e) |
void |
addAll(NonOverlappingIntervalList other)
Adds all of the intervals contained in another list to this list.
|
void |
addAll(NonOverlappingIntervalList other,
int firstIndex,
int lastIndex,
boolean moveToFront)
Adds all or a part of the intervals contained in another list to this list.
|
boolean |
contains(int pos)
Returns
true if the specified position is marked by this list. |
boolean |
containsAll(int firstPos,
int lastPos)
Returns
true if all positions in the specified interval are marked by this list. |
SortedSet<SimpleSequenceInterval> |
getOverlappingElements(int firstPos,
int lastPos) |
void |
movePositions(int start,
int offset) |
addAll, ceiling, clear, clone, comparator, contains, descendingIterator, descendingSet, first, floor, headSet, headSet, higher, isEmpty, iterator, last, lower, pollFirst, pollLast, remove, size, subSet, subSet, tailSet, tailSet
equals, hashCode, removeAll
containsAll, retainAll, toArray, toArray, toString
public NonOverlappingIntervalList()
public boolean add(SimpleSequenceInterval e)
add
in interface Collection<SimpleSequenceInterval>
add
in interface Set<SimpleSequenceInterval>
add
in class TreeSet<SimpleSequenceInterval>
public boolean add(int pos)
public boolean add(int firstPos, int lastPos)
public void addAll(NonOverlappingIntervalList other, int firstIndex, int lastIndex, boolean moveToFront)
other
- the other list instancefirstIndex
- the first position from where to start the import (must be >= 0
)lastIndex
- the index after the last position to be imported (must be > firstIndex
).moveToFront
- Specify true
here, if you want to move the imported intervals to the
front of the target list. (An interval starting at firstIndex
would than start at 0
in the target list.)public void addAll(NonOverlappingIntervalList other)
addAll(other, 0, other.last().getLastPos() + 1, false)
.other
- the other list instancepublic void movePositions(int start, int offset)
public boolean contains(int pos)
true
if the specified position is marked by this list.public boolean containsAll(int firstPos, int lastPos)
true
if all positions in the specified interval are marked by this list.public SortedSet<SimpleSequenceInterval> getOverlappingElements(int firstPos, int lastPos)